DockerProject/docker-compose.service
2024-04-22 13:04:31 +04:00

13 lines
420 B
Desktop File

[Unit]
Description=Some personal Docker containers
After=docker.service
Requires=docker.service
[Service]
Type=oneshot
RemainAfterExit=yes # чтобы считать службу активной после завершения процесса
ExecStart=docker compose -f /opt/project/docker-compose.yml up --detach
ExecStop=docker compose -f /opt/project/docker-compose.yml stop
[Install]
WantedBy=multi-user.target