diff options
Diffstat (limited to 'docker/schedule.sh')
-rwxr-xr-x | docker/schedule.sh | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/docker/schedule.sh b/docker/schedule.sh index 0f3fa20..db7ae26 100755 --- a/docker/schedule.sh +++ b/docker/schedule.sh @@ -42,8 +42,10 @@ setup_cron_task() { make_task_script "$@" > /task.sh chmod +x /task.sh - # Run the task once when the container is started, regardless of schedule. - /task.sh + if [ -n "$SCHEDULE_ON_START" ]; then + # Run the task once when the container is started. + /task.sh + fi local crontab crontab="$schedule /task.sh |