Changeset - a6897a0f7232
[Not reviewed]
0 1 1
Ben Sturmfels (bsturmfels) - 5 months ago 2023-11-25 02:41:55
ben@sturm.com.au
Add the conservancy-www-db.path Systemd file

This runs the SQL update when the relevant file is modified.
2 files changed with 15 insertions and 5 deletions:
0 comments (0 inline, 0 general)
systemd/README.md
Show inline comments
 
# SystemD services
 
# Systemd services
 

	
 
## Installing
 

	
 
Install all SystemD services with:
 
Install all Systemd services with:
 

	
 
    cp systemd/conservancy-www-*.{service,timer} /etc/systemd/system
 
    systemctl enable conservancy-www-cleanup.service
...
 
@@ -10,6 +10,7 @@ Install all SystemD services with:
 
    systemctl enable conservancy-www-update.timer
 
    systemctl start conservancy-www-update.timer
 
    systemctl enable conservancy-www-db.service
 
    systemctl start conservancy-www-db.path
 

	
 

	
 
##  Website updates
...
 
@@ -29,6 +30,6 @@ Note that the update script does not run `migrate`.
 

	
 
## Fundraiser/sustainer database updates
 

	
 
The `conservancy-www-db.service` applies SQL updates to the website
 
database. These include the fundraising total and sustainers to be publicly
 
acknowledged.
 
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.
systemd/conservancy-www-db.path
Show inline comments
 
new file 100644
 
[Unit]
 
Description=Update Conservancy website database
 
Before=apache2.service
 

	
 
[Path]
 
PathChanged=/home/debian/django-supporters-list.sql
 

	
 
[Install]
 
WantedBy=apache2.service
0 comments (0 inline, 0 general)