refactor(luna): delay gitlab-docker start in systemd

This commit is contained in:
Price Hiller 2023-12-08 10:36:18 -06:00
parent 34c78f67b0
commit d6c7a522ef
Signed by: Price
SSH Key Fingerprint: SHA256:Y4S9ZzYphRn1W1kbJerJFO6GGsfu9O70VaBSxJO7dF8

View File

@ -7,6 +7,16 @@ in
environment.persistence.save.directories = [
gitlab_home
];
systemd.timers.delay-gitlab-start = {
after = [ "docker.service" "docker.socket" "network-online.target" ];
wantedBy = [ "timers.target" ];
timerConfig = {
OnActiveSec = "30sec";
Unit = "docker-gitlab.service";
};
};
virtualisation.oci-containers.containers.gitlab = {
image = "gitlab/gitlab-ee:latest";
autoStart = true;
@ -26,6 +36,8 @@ in
];
};
systemd.services.docker-gitlab.after = [ "delay-gitlab.timer" ];
networking.firewall.allowedTCPPorts = [
2222
];