workadventure: Config upgrade for latest version #56
|
@ -6,6 +6,20 @@
|
|||
- name: Install docker-compose
|
||||
apt: name=docker-compose
|
||||
|
||||
- name: Install git
|
||||
apt: name=git
|
||||
|
||||
- name: Create workadventure group
|
||||
group: name=workadventure
|
||||
|
||||
- name: Create workadventure user
|
||||
user:
|
||||
name: workadventure
|
||||
home: /opt/workadventure
|
||||
shell: /bin/zsh
|
||||
group: workadventure
|
||||
groups: docker
|
||||
|
||||
- name: Install systemd unit
|
||||
template: src=workadventure.service.j2 dest=/lib/systemd/system/workadventure.service
|
||||
notify:
|
||||
|
|
|
@ -38,7 +38,7 @@ server {
|
|||
ssl_certificate /etc/nginx/ssl/{{ workadventure_domain }}.crt;
|
||||
|
||||
location / {
|
||||
root /opt/workadventure/source/front/dist;
|
||||
root /opt/workadventure/source/src/front/dist;
|
||||
try_files $uri uri/ /index.html?$args;
|
||||
}
|
||||
}
|
||||
|
@ -73,4 +73,4 @@ server {
|
|||
location / {
|
||||
proxy_pass http://localhost:8005;
|
||||
}
|
||||
}
|
||||
}
|
|
@ -2,6 +2,7 @@
|
|||
Description=WorkAdventure service using docker compose
|
||||
Requires=docker.service
|
||||
After=docker.service
|
||||
Before=nginx.service
|
||||
|
||||
[Service]
|
||||
Type=simple
|
||||
|
@ -15,13 +16,13 @@ TimeoutStartSec=1200
|
|||
WorkingDirectory=/opt/workadventure/source/
|
||||
|
||||
# Make sure no old containers are running
|
||||
ExecStartPre=/usr/bin/docker-compose -f docker-compose.bk.yaml down -v
|
||||
ExecStartPre=/usr/bin/docker-compose down -v
|
||||
|
||||
# Compose up
|
||||
ExecStart=/usr/bin/docker-compose -f docker-compose.bk.yaml up
|
||||
ExecStart=/usr/bin/docker-compose up
|
||||
|
||||
# Compose down, remove containers and volumes
|
||||
ExecStop=/usr/bin/docker-compose -f docker-compose.bk.yaml down -v
|
||||
ExecStop=/usr/bin/docker-compose down -v
|
||||
|
||||
[Install]
|
||||
WantedBy=multi-user.target
|
||||
|
|
Loading…
Reference in New Issue