From 01f3b3236dfb93e232f66002c82baf176b804f6c Mon Sep 17 00:00:00 2001 From: neil Date: Tue, 6 Jun 2017 10:10:52 +0800 Subject: [PATCH] fix cronjob --- Procfile | 3 ++- updatessl.sh | 10 ---------- 2 files changed, 2 insertions(+), 11 deletions(-) diff --git a/Procfile b/Procfile index b7346ac..a96a1ab 100644 --- a/Procfile +++ b/Procfile @@ -1,2 +1,3 @@ dockergen: docker-gen -watch -notify "/app/updatessl.sh updatessl" /app/nginx.tmpl /etc/nginx/conf.d/default.conf -nginx: nginx \ No newline at end of file +nginx: nginx +cron: cron -f \ No newline at end of file diff --git a/updatessl.sh b/updatessl.sh index 394b2f5..f939967 100755 --- a/updatessl.sh +++ b/updatessl.sh @@ -10,15 +10,6 @@ DEFAULT_CONF="/etc/nginx/conf.d/default.conf" CERTS="/etc/nginx/certs" -startcron() { - if service cron status | grep "cron is running"; then - echo "cron is running, skip" - else - service cron start - fi -} - - updatessl() { if grep ACME_DOMAINS $DEFAULT_CONF ; then @@ -42,7 +33,6 @@ updatessl() { } -startcron "$@"