add logrotate

pull/3/head
Adrien Beudin 10 years ago
parent f670ef1fc0
commit c6dbb53709

@ -0,0 +1,9 @@
"/var/log/ffsync.log" {
copytruncate
daily
rotate 7
compress
delaycompress
missingok
notifempty
}

@ -38,6 +38,7 @@ final_path=/opt/yunohost/ffsync
sudo mkdir -p $final_path sudo mkdir -p $final_path
sudo cp -a ../sources/* $final_path sudo cp -a ../sources/* $final_path
sudo cp ../conf/ffsync /etc/init.d/ sudo cp ../conf/ffsync /etc/init.d/
sudo cp ../conf/ffsync.logrotate /etc/logrotate.d/ffsync
# Set permissions to ffsync directory # Set permissions to ffsync directory
sudo useradd ffsync -d $final_path sudo useradd ffsync -d $final_path

@ -11,7 +11,7 @@ sudo rm -f /etc/nginx/conf.d/$domain.d/ffsync.conf
sudo service ffsync stop sudo service ffsync stop
sudo update-rc.d ffsync remove sudo update-rc.d ffsync remove
sudo rm /etc/init.d/ffsync sudo rm /etc/init.d/ffsync
sudo rm /etc/logrotate.d/ffsync
sudo service nginx reload sudo service nginx reload
sudo userdel ffsync sudo userdel ffsync

@ -20,6 +20,7 @@ final_path=/opt/yunohost/ffsync
sudo mkdir -p $final_path sudo mkdir -p $final_path
sudo cp -a ../sources/* $final_path sudo cp -a ../sources/* $final_path
sudo cp ../conf/ffsync /etc/init.d/ sudo cp ../conf/ffsync /etc/init.d/
sudo cp ../conf/ffsync.logrotate /etc/logrotate.d/ffsync
# Set permissions to ffsync directory # Set permissions to ffsync directory
sudo useradd ffsync -d $final_path sudo useradd ffsync -d $final_path

Loading…
Cancel
Save