refactored job script, added profiles