dedis / popstellar

Proof-of-personhood System
GNU Affero General Public License v3.0
35 stars 8 forks source link

[BUG] The deployment of the CD pipeline (server-side) is broken #1858

Open pierluca opened 3 months ago

pierluca commented 3 months ago

Description (Actual behavior)

When a new release is made, the PoP backend software wasn't restarted. (a temporary fix is now in place for dev-be{1,2}-{a,b}.personhood.online)

Expected behavior

When a new release is made, the PoP backends should be restarted automatically with the new version.

How to reproduce

  1. Generate a new release
  2. Go on the server
  3. Check the uptime of systemctl status pop-dev-be1-go.service
  4. It should be seconds, it's much longer

Version & Environment

This bug was reproduced on May 15, 2024 (github.com/dedis/ansible-config is the relevant repo)

Front-ends:
Back-ends:

Workaround

systemctl restart of each service - not a valid option.

Possible root cause

Most likely, since the Debian Bullseye update, the previous service descriptions don't work anymore.

pierluca commented 3 months ago

Good scripts , to be included in ansible-config

pop-dev-be1-go-a-restart.path

[Path]
PathModified=/home/popdemo/dev/be1-go/pop

[Install]
WantedBy=multi-user.target

pop-dev-be1-go-a-restart.service

[Unit]
Description=pop-dev-be1-go-a restarter
After=network.target

[Service]
Type=oneshot
ExecStart=/usr/bin/systemctl restart pop-dev-be1-go-a.service

[Install]
WantedBy=multi-user.target

Enabling commands

$ systemctl enable pop*restart.{path,service}
$ systemctl start pop*restart.{path,service}