2023-11-25 02:21:33 +00:00
|
|
|
# Systemd services
|
2023-11-23 23:01:34 +00:00
|
|
|
|
|
|
|
## Installing
|
|
|
|
|
2023-11-25 02:21:33 +00:00
|
|
|
Install all Systemd services with:
|
2023-09-14 08:14:22 +00:00
|
|
|
|
|
|
|
cp systemd/conservancy-www-*.{service,timer} /etc/systemd/system
|
|
|
|
systemctl enable conservancy-www-cleanup.service
|
|
|
|
systemctl start conservancy-www-cleanup.service
|
|
|
|
systemctl enable conservancy-www-update.timer
|
|
|
|
systemctl start conservancy-www-update.timer
|
2023-11-23 23:01:34 +00:00
|
|
|
systemctl enable conservancy-www-db.service
|
2023-11-25 02:21:33 +00:00
|
|
|
systemctl start conservancy-www-db.path
|
2023-11-23 23:01:34 +00:00
|
|
|
|
|
|
|
|
|
|
|
## Website updates
|
2023-09-14 08:14:22 +00:00
|
|
|
|
2023-11-23 23:01:34 +00:00
|
|
|
Monitor the website update service with:
|
2023-09-14 08:14:22 +00:00
|
|
|
|
|
|
|
systemctl list-timers --all
|
|
|
|
journalctl --catalog --follow --unit conservancy-www-update.service
|
|
|
|
|
|
|
|
Updates will fail unless `/var/www/website` has a git upstream, so set that with:
|
|
|
|
|
|
|
|
git remote add upstream https://k.sfconservancy.org/website
|
|
|
|
git branch --set-upstream-to=upstream/master master
|
2023-09-14 08:21:00 +00:00
|
|
|
|
|
|
|
Note that the update script does not run `migrate`.
|
2023-11-23 23:01:34 +00:00
|
|
|
|
|
|
|
|
|
|
|
## Fundraiser/sustainer database updates
|
|
|
|
|
2023-11-25 02:21:33 +00:00
|
|
|
The `conservancy-www-db.service` applies SQL updates to the website database
|
|
|
|
automatically when the file `django-supporters-list.sql` file is modified. These
|
|
|
|
include the fundraising total and sustainers to be publicly acknowledged.
|