bundles/travelynx: prepare for bookworm

This commit is contained in:
Franzi 2023-08-01 21:21:31 +02:00
parent 3826ccf4ec
commit c121110f00
Signed by: kunsi
GPG key ID: 12E3D2136B818350
4 changed files with 17 additions and 7 deletions

View file

@ -40,6 +40,9 @@
secrets => [ secrets => [
'${cookie_secret}', '${cookie_secret}',
% for i in sorted(additional_cookie_secrets):
'${i}',
% endfor
], ],
version => '${version}', version => '${version}',

View file

@ -8,9 +8,9 @@ Type=simple
RemainAfterExit=yes RemainAfterExit=yes
PIDFile=/var/cache/travelynx/travelynx.pid PIDFile=/var/cache/travelynx/travelynx.pid
ExecStart=/usr/local/bin/hypnotoad -f index.pl ExecStart=/usr/bin/hypnotoad -f index.pl
ExecStop=/usr/local/bin/hypnotoad -s index.pl ExecStop=/usr/bin/hypnotoad -s index.pl
ExecReload=/usr/local/bin/hypnotoad index.pl ExecReload=/usr/bin/hypnotoad index.pl
User=travelynx User=travelynx
WorkingDirectory=/opt/travelynx WorkingDirectory=/opt/travelynx

View file

@ -20,14 +20,14 @@ directories = {
} }
files = { files = {
'/etc/systemd/system/travelynx.service': { '/usr/local/lib/systemd/system/travelynx.service': {
'triggers': { 'triggers': {
'action:systemd-reload', 'action:systemd-reload',
'svc_systemd:travelynx:restart', 'svc_systemd:travelynx:restart',
'svc_systemd:travelynx-worker:restart', 'svc_systemd:travelynx-worker:restart',
}, },
}, },
'/etc/systemd/system/travelynx-worker.service': { '/usr/local/lib/systemd/system/travelynx-worker.service': {
'triggers': { 'triggers': {
'action:systemd-reload', 'action:systemd-reload',
'svc_systemd:travelynx:restart', 'svc_systemd:travelynx:restart',
@ -102,14 +102,15 @@ actions = {
svc_systemd = { svc_systemd = {
'travelynx': { 'travelynx': {
'needs': { 'needs': {
'file:/etc/systemd/system/travelynx.service', 'file:/usr/local/lib/systemd/system/travelynx.service',
'action:travelynx_database_migrate', 'action:travelynx_database_migrate',
'directory:/var/cache/travelynx', 'directory:/var/cache/travelynx',
'pkg_apt:libmojolicious-perl',
}, },
}, },
'travelynx-worker': { 'travelynx-worker': {
'needs': { 'needs': {
'file:/etc/systemd/system/travelynx-worker.service', 'file:/usr/local/lib/systemd/system/travelynx-worker.service',
'svc_systemd:travelynx', 'svc_systemd:travelynx',
}, },
}, },

View file

@ -1,4 +1,9 @@
defaults = { defaults = {
'apt': {
'packages': {
'libmojolicious-perl': {},
},
},
'travelynx': { 'travelynx': {
'database': { 'database': {
'username': 'travelynx', 'username': 'travelynx',
@ -9,6 +14,7 @@ defaults = {
'spare_workers': 2, 'spare_workers': 2,
'mail_from': 'travelynx@{}'.format(node.hostname), 'mail_from': 'travelynx@{}'.format(node.hostname),
'cookie_secret': repo.vault.password_for('{} travelynx cookie_secret'.format(node.name)), 'cookie_secret': repo.vault.password_for('{} travelynx cookie_secret'.format(node.name)),
'additional_cookie_secrets': set(),
}, },
'postgresql': { 'postgresql': {
'roles': { 'roles': {