diff --git a/monkey/infection_monkey/post_breach/job_scheduling/linux_job_scheduling.py b/monkey/infection_monkey/post_breach/job_scheduling/linux_job_scheduling.py index 8a4046c88..4ed5ff970 100644 --- a/monkey/infection_monkey/post_breach/job_scheduling/linux_job_scheduling.py +++ b/monkey/infection_monkey/post_breach/job_scheduling/linux_job_scheduling.py @@ -7,6 +7,6 @@ def get_linux_commands_to_schedule_jobs(): f'crontab -l > {TEMP_CRON} &&', 'echo \"# Successfully scheduled a job using crontab\" |', f'tee -a {TEMP_CRON} &&', - f'crontab {TEMP_CRON} &&', + f'crontab {TEMP_CRON} ;', f'rm {TEMP_CRON}' ]