]> git.immae.eu Git - perso/Immae/Projets/Puppet.git/commitdiff
Make bot quiet and use timezone to have correct start time
authorIsmaël Bouya <ismael.bouya@normalesup.org>
Sun, 25 Mar 2018 22:24:47 +0000 (00:24 +0200)
committerIsmaël Bouya <ismael.bouya@normalesup.org>
Sun, 25 Mar 2018 22:24:47 +0000 (00:24 +0200)
modules/role/manifests/cryptoportfolio/bot.pp

index a15c779f6f1f7c8164b583e9b68b4bbba3091b84..d8b377f255bb0885585090b418aface92f596f42 100644 (file)
@@ -56,12 +56,12 @@ class role::cryptoportfolio::bot inherits role::cryptoportfolio {
 
   cron { "py-cryptoportfolio-before":
     ensure      => present,
-    command     => "cd $cf_bot_app ; python main.py --config $cf_bot_app_conf --before",
+    command     => "cd $cf_bot_app ; python main.py --quiet --config $cf_bot_app_conf --before",
     user        => $user,
     weekday     => 7, # Sunday
     hour        => 22,
     minute      => 30,
-    environment => ["HOME=${home}","PATH=/usr/bin/"],
+    environment => ["HOME=${home}","PATH=/usr/bin/","CRON_TZ=UTC"],
     require     => [
       File[$cf_bot_app_conf],
       Archive["${home}/trader_${bot_version}.tar.gz"]
@@ -70,12 +70,12 @@ class role::cryptoportfolio::bot inherits role::cryptoportfolio {
 
   cron { "py-cryptoportfolio-after":
     ensure      => present,
-    command     => "cd $cf_bot_app ; python main.py --config $cf_bot_app_conf --after",
+    command     => "cd $cf_bot_app ; python main.py --quiet --config $cf_bot_app_conf --after",
     user        => $user,
     weekday     => 1, # Monday
-    hour        => 1,
+    hour        => 0,
     minute      => 0,
-    environment => ["HOME=${home}","PATH=/usr/bin/"],
+    environment => ["HOME=${home}","PATH=/usr/bin/","CRON_TZ=UTC"],
     require     => [
       File[$cf_bot_app_conf],
       Archive["${home}/trader_${bot_version}.tar.gz"]