Deploy tweaks
This commit is contained in:
+1
-1
@@ -6,4 +6,4 @@ services:
|
|||||||
- ~/.composer-docker/cache:/root/.composer/cache:delegated
|
- ~/.composer-docker/cache:/root/.composer/cache:delegated
|
||||||
- ./:/app:delegated
|
- ./:/app:delegated
|
||||||
ports:
|
ports:
|
||||||
- '8000:80'
|
- '8889:80'
|
||||||
|
|||||||
@@ -0,0 +1,17 @@
|
|||||||
|
[Unit]
|
||||||
|
Description=glade_cameras
|
||||||
|
Requires=docker.service
|
||||||
|
After=docker.service
|
||||||
|
[Service]
|
||||||
|
Restart=always
|
||||||
|
User=root
|
||||||
|
Group=docker
|
||||||
|
WorkingDirectory=/mnt/storage/glade/glade_cameras
|
||||||
|
# Shutdown container (if running) when unit is started
|
||||||
|
ExecStartPre=/usr/bin/docker compose -f docker-compose.yml down
|
||||||
|
# Start container when unit is started
|
||||||
|
ExecStart=/usr/bin/docker compose -f docker-compose.yml up
|
||||||
|
# Stop container when unit is stopped
|
||||||
|
ExecStop=/usr/bin/docker compose -f docker-compose.yml down
|
||||||
|
[Install]
|
||||||
|
WantedBy=multi-user.target
|
||||||
Reference in New Issue
Block a user