This PR adds an option to configure a scheduled command to run in the background. This feature is particularly useful for jobs that take a significant amount of time to complete, as it prevents subsequent scheduled jobs from being delayed.
Implementation Details
By default, commands are triggered by calling the CI helper:
command('command:name');
When a job is configured to run in the background, this default behavior is bypassed. Instead, the job is executed using the current shell execution:
Description
This PR adds an option to configure a scheduled command to run in the background. This feature is particularly useful for jobs that take a significant amount of time to complete, as it prevents subsequent scheduled jobs from being delayed.
Implementation Details
By default, commands are triggered by calling the CI helper:
When a job is configured to run in the background, this default behavior is bypassed. Instead, the job is executed using the current shell execution:
Key Components:
Additionally, the
cronjob:finish
command is responsible for setting the cronjob status to "stopped," allowing it to run again without issues.