install/systemd: tglist-sync timer for follower boxes; INSTALL.md notes on systemd/cron
Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
This commit is contained in:
+28
@@ -144,6 +144,34 @@ sudo systemd-tmpfiles --create /etc/tmpfiles.d/svxportal-tglist.conf
|
||||
This creates `/etc/svxlink/tglist.json` owned by `www-data`. The path is
|
||||
`tglist_file` in `config.php`; change both if you want it elsewhere.
|
||||
|
||||
### 6b. Optional: follower box that mirrors another portal's talkgroup list
|
||||
|
||||
If you run several reflectors and want ONE talkgroup list, one portal is the
|
||||
master (its list is edited in the web) and the others pull it four times a day
|
||||
with a systemd timer. Nothing but `curl` and `python3` is involved.
|
||||
|
||||
```bash
|
||||
sudo cp install/systemd/svxportal-tglist-sync.service install/systemd/svxportal-tglist-sync.timer /etc/systemd/system/
|
||||
sudo cp install/systemd/tglist-sync.sh /etc/svxlink/tglist-sync.sh && sudo chmod 755 /etc/svxlink/tglist-sync.sh
|
||||
sudo cp install/systemd/default-svxportal-tglist-sync /etc/default/svxportal-tglist-sync
|
||||
sudoedit /etc/default/svxportal-tglist-sync # UPSTREAM = the master's https://.../tglist.php
|
||||
sudo systemctl daemon-reload
|
||||
sudo systemctl enable --now svxportal-tglist-sync.timer
|
||||
sudo systemctl start svxportal-tglist-sync.service && journalctl -u svxportal-tglist-sync -n 3
|
||||
```
|
||||
|
||||
On the master, or on a standalone box, do **not** install this (or leave
|
||||
`UPSTREAM` empty; the script then exits without touching the file).
|
||||
|
||||
Other systemd notes:
|
||||
|
||||
- `svxreflector.service` is used **unmodified** from the SvxLink package. No
|
||||
drop-in is needed for the portal.
|
||||
- Redis runs from Debian's `redis-server@.service` template (step 3); no unit
|
||||
file to add.
|
||||
- There are no cron jobs. PHP session cleanup is Debian's stock
|
||||
`phpsessionclean.timer`.
|
||||
|
||||
## 7. nginx + TLS
|
||||
|
||||
```bash
|
||||
|
||||
Reference in New Issue
Block a user