obs-portal: init obs-portal on nachtigall #115

Merged
teutat3s merged 5 commits from feat/obs-portal-nachtigall into main 2024-04-27 23:14:50 +00:00
Showing only changes of commit 1d6c5003e8 - Show all commits

View file

@ -59,7 +59,8 @@ in {
in in
{ {
serviceConfig.Type = "oneshot"; serviceConfig.Type = "oneshot";
before = [ "docker-obs-portal.service" ]; before = [ "docker-obs-portal.service" "docker-obs-portal-db.service" "docker-obs-portal-worker.service" ];
requiredBy = [ "docker-obs-portal.service" "docker-obs-portal-db.service" "docker-obs-portal-worker.service" ];
script = '' script = ''
${dockerBin} network inspect obs-portal-net >/dev/null 2>&1 || ${dockerBin} network create obs-portal-net --subnet 172.20.0.0/24 ${dockerBin} network inspect obs-portal-net >/dev/null 2>&1 || ${dockerBin} network create obs-portal-net --subnet 172.20.0.0/24
''; '';
@ -85,7 +86,11 @@ in {
containers."obs-portal" = { containers."obs-portal" = {
image = "git.pub.solar/pub-solar/obs-portal:latest"; image = "git.pub.solar/pub-solar/obs-portal:latest";
autoStart = true; autoStart = true;
ports = [ "localhost:3001:${env.OBS_PORT}" ]; ports = [ "127.0.0.1:3001:${env.OBS_PORT}" ];
dependsOn = [
"obs-portal-db"
"obs-portal-worker"
];
environment = env; environment = env;
environmentFiles = [ config.age.secrets.obs-portal-env.path ]; environmentFiles = [ config.age.secrets.obs-portal-env.path ];