2021-01-13 16:36:50 +00:00
|
|
|
[Unit]
|
2021-12-06 11:58:01 +00:00
|
|
|
Description=Git Server via SSH
|
|
|
|
Wants=container-build@%N.service container-volume@%N.service container-volume@%N-serve.service
|
|
|
|
After=container-build@%N.service container-volume@%N.service container-volume@%N-serve.service
|
2021-01-13 16:36:50 +00:00
|
|
|
|
|
|
|
[Service]
|
2021-08-14 21:28:28 +00:00
|
|
|
Type=notify
|
|
|
|
NotifyAccess=all
|
2021-08-28 18:16:29 +00:00
|
|
|
SyslogIdentifier=%N
|
2021-08-14 21:28:28 +00:00
|
|
|
Restart=on-failure
|
|
|
|
Environment=PODMAN_SYSTEMD_UNIT=%n
|
2021-09-08 17:45:04 +00:00
|
|
|
ExecStart=/bin/podman run --replace --name %N --net internal --sdnotify=conmon --cap-add AUDIT_WRITE \
|
2021-03-27 23:03:56 +00:00
|
|
|
--publish 468:22 \
|
2021-06-30 21:41:32 +00:00
|
|
|
--volume %N:/var/lib/git:z \
|
2021-12-06 11:58:01 +00:00
|
|
|
--volume %N-serve:/var/lib/git-serve:z \
|
2021-06-30 21:41:32 +00:00
|
|
|
--volume %N-ssh:/etc/ssh/keys:z \
|
|
|
|
localhost/%N:latest
|
2021-08-14 21:28:28 +00:00
|
|
|
ExecStop=/bin/podman stop --ignore --time 10 %N
|
|
|
|
ExecStopPost=/bin/podman rm --ignore --force %N
|
2021-01-13 16:36:50 +00:00
|
|
|
|
|
|
|
[Install]
|
|
|
|
WantedBy=multi-user.target
|