Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

/root/update-everything.sh cronning needs to be added #14

Open
mvl22 opened this issue Nov 1, 2012 · 1 comment
Open

/root/update-everything.sh cronning needs to be added #14

mvl22 opened this issue Nov 1, 2012 · 1 comment

Comments

@mvl22
Copy link
Member

mvl22 commented Nov 1, 2012

There is currently a manually-created cron job

7 * * * * /bin/bash /root/monitor-update.sh

and a file /root/monitor-update.sh (which should probably be renamed to update-toolkit.sh or similar) containing:


/root/update-everything.sh > /root/update_everything.log 2>&1
if [[ $? -ne 0 ]]; then
/usr/bin/mailx -s "Crontab error" anemailaddresshere@example.com <<EndOfMail

It looks like there was a problem with the update_everything script at

`date`

tail /root/update_everything.log

@`tail /root/update_everything.log`
@

========

tail /var/log/chef/solo.log

@`tail /var/log/chef/solo.log`
@

========

That's all for now. Good luck.

EndOfMail
fi
exit 0

and which runs a script /root/update-everything.sh

set -e

pushd /opt/toolkit-chef
git pull
pushd /opt
chef-solo -c toolkit-chef/solo.rb -j toolkit-chef/node.json

It would be good if the setup of all this could be put into the main chef installation (and ideally integrated as a single script perhaps?).

@mvl22
Copy link
Member Author

mvl22 commented Mar 18, 2014

I ran into this again this week.

This extra requirement is currently documented in the README at
https://github.com/cyclestreets/toolkit-servermigration/blob/master/README.md
but would be good to put into the main installation.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant