issue #0002043 : Ajout de configuration spécifique en dehors de l'installation
This commit is contained in:
parent
a167e23c09
commit
34dad882aa
@ -133,10 +133,14 @@ if ( $opts->incron ) {
|
||||
|
||||
echo "Création configuration incron.\n";
|
||||
|
||||
if ( file_exist('/etc/incron.d') ) {
|
||||
file_put_contents('/etc/incron.d/bilanclient', $c->profil->path->data . "/bilanclient IN_CLOSE_WRITE php /home/vhosts/extranet/scripts/jobs/sendBilanClient.php --file $#");
|
||||
if ( !file_exist('/etc/incron.d') ) {
|
||||
echo "incron is not install !\n";
|
||||
exit;
|
||||
}
|
||||
|
||||
//Send bilanclient
|
||||
file_put_contents('/etc/incron.d/bilanclient', $c->profil->path->data . "/bilanclient IN_CLOSE_WRITE php /home/vhosts/extranet/scripts/jobs/sendBilanClient.php --file $#");
|
||||
|
||||
echo "Don't forget to restart incron. sudo service incron restart.\n";
|
||||
echo "Fin de la configuration.\n";
|
||||
}
|
||||
@ -145,6 +149,15 @@ if ( $opts->cron ) {
|
||||
|
||||
echo "Création configuration cron.\n";
|
||||
|
||||
if ( !file_exist('/etc/cron.d') ) {
|
||||
echo "cron is not install !\n";
|
||||
exit;
|
||||
}
|
||||
|
||||
//AltiScore
|
||||
file_put_contents('/etc/cron.d/altiscore', "# AltiScore");
|
||||
file_put_contents('/etc/cron.d/altiscore', "00 04 * * 1-5 www-data php /home/vhosts/extranet/scripts/jobs/getAltiScore.php --cron >> /home/vhosts/data/log/altiscore.log", FILE_APPEND);
|
||||
|
||||
echo "Don't forget to restart cron. sudo service cron restart.";
|
||||
echo "End.\n";
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user