Merge branch 'cronjob-as-gitlab-ci' into 'master'
Move cron job from root to the gitlab-ci user With the new gitlab-rake wrapper it is no longer necessary to use root's crontab. See merge request !367
This commit is contained in:
commit
4b9926b8c0
|
@ -15,8 +15,15 @@
|
|||
# limitations under the License.
|
||||
#
|
||||
|
||||
# Remove the old cronjob from root's crontab
|
||||
cron 'gitlab-ci schedule builds' do
|
||||
user 'root'
|
||||
action :delete
|
||||
end
|
||||
|
||||
cron 'gitlab-ci schedule builds' do
|
||||
minute node['gitlab']['gitlab-ci']['schedule_builds_minute']
|
||||
command '/opt/gitlab/bin/gitlab-ci-rake schedule_builds'
|
||||
user node['gitlab']['gitlab-ci']['username']
|
||||
action node['gitlab']['gitlab-ci']['enable'] ? :create : :delete
|
||||
end
|
||||
|
|
Loading…
Reference in New Issue