kopia lustrzana https://github.com/jprochazka/adsb-receiver
Cron for graphs ran from file in cron.d
rodzic
96e991f423
commit
c39648d43a
|
@ -231,15 +231,14 @@ sudo cp -r $BUILDDIR/portal/graphs/html/* /var/www/html/graphs/
|
||||||
echo -e "\033[33mAdding jobs to crontab..."
|
echo -e "\033[33mAdding jobs to crontab..."
|
||||||
echo -e "\033[37m"
|
echo -e "\033[37m"
|
||||||
chmod 755 $BUILDDIR/portal/graphs/make-collectd-graphs.sh
|
chmod 755 $BUILDDIR/portal/graphs/make-collectd-graphs.sh
|
||||||
crontab -l > crontents
|
sudo tee -a /etc/cron.d/feeder-performance-graphs > /dev/null <<EOF
|
||||||
echo "*/5 * * * * sudo ${BUILDDIR}/portal/graphs/make-collectd-graphs.sh 1h >/dev/null" >> crontents
|
*/5 * * * * root bash ${BUILDDIR}/portal/graphs/make-collectd-graphs.sh 1h >/dev/null
|
||||||
echo "*/10 * * * * sudo ${BUILDDIR}/portal/graphs/make-collectd-graphs.sh 6h >/dev/null" >> crontents
|
*/10 * * * * root bash ${BUILDDIR}/portal/graphs/make-collectd-graphs.sh 6h >/dev/null
|
||||||
echo "2,12,22,32,42,52 * * * * sudo ${BUILDDIR}/portal/graphs/make-collectd-graphs.sh 24h 180 >/dev/null" >> crontents
|
2,12,22,32,42,52 * * * * root bash ${BUILDDIR}/portal/graphs/make-collectd-graphs.sh 24h 180 >/dev/null
|
||||||
echo "4,24,44 * * * * sudo ${BUILDDIR}/portal/graphs/make-collectd-graphs.sh 7d 1200 >/dev/null" >> crontents
|
4,24,44 * * * * root bash ${BUILDDIR}/portal/graphs/make-collectd-graphs.sh 7d 1200 >/dev/null
|
||||||
echo "6 * * * * sudo ${BUILDDIR}/portal/graphs/make-collectd-graphs.sh 30d 5400 >/dev/null" >> crontents
|
6 * * * * root bash ${BUILDDIR}/portal/graphs/make-collectd-graphs.sh 30d 5400 >/dev/null
|
||||||
echo "8 */12 * * * sudo ${BUILDDIR}/portal/graphs/make-collectd-graphs.sh 365d 86400 >/dev/null" >> crontents
|
8 */12 * * * root bash ${BUILDDIR}/portal/graphs/make-collectd-graphs.sh 365d 86400 >/dev/null
|
||||||
crontab crontents
|
EOF
|
||||||
rm crontents
|
|
||||||
|
|
||||||
echo -e "\033[33m"
|
echo -e "\033[33m"
|
||||||
echo "Installation and configuration of the performance graphs is now complete."
|
echo "Installation and configuration of the performance graphs is now complete."
|
||||||
|
|
Ładowanie…
Reference in New Issue