mirror of
https://github.com/Websoft9/websoft9.git
synced 2025-02-03 01:28:39 +08:00
Update main.yml
This commit is contained in:
parent
bbb776be7b
commit
b72ddb1ede
@ -1,6 +1,6 @@
|
|||||||
- name: Rename and Run docker-compose
|
- name: Rename and Run docker-compose
|
||||||
shell: |
|
shell: |
|
||||||
docker-compose up -d
|
docker compose up -d
|
||||||
sleep 30
|
sleep 30
|
||||||
args:
|
args:
|
||||||
chdir: "{{installpath}}/{{appname}}"
|
chdir: "{{installpath}}/{{appname}}"
|
||||||
@ -11,9 +11,9 @@
|
|||||||
state: directory
|
state: directory
|
||||||
recurse: yes
|
recurse: yes
|
||||||
with_items:
|
with_items:
|
||||||
- "{{installpath}}/{{appname}}/volumes"
|
- "{{installpath}}/{{appname}}/data"
|
||||||
|
|
||||||
- name: Set softlink of all volumes
|
- name: Add softlink of all volumes for app root directory
|
||||||
block:
|
block:
|
||||||
- name: Get volumes name
|
- name: Get volumes name
|
||||||
shell: docker-compose config --volumes
|
shell: docker-compose config --volumes
|
||||||
@ -24,7 +24,7 @@
|
|||||||
- name: Create softlink of volumes
|
- name: Create softlink of volumes
|
||||||
file:
|
file:
|
||||||
src: "/var/lib/docker/volumes/{{appname}}_{{item}}/_data"
|
src: "/var/lib/docker/volumes/{{appname}}_{{item}}/_data"
|
||||||
dest: "{{installpath}}/{{appname}}/volumes/{{item}}"
|
dest: "{{installpath}}/{{appname}}/data/{{item}}"
|
||||||
state: link
|
state: link
|
||||||
force: yes
|
force: yes
|
||||||
loop: "{{volume_names.stdout_lines}}"
|
loop: "{{volume_names.stdout_lines}}"
|
||||||
|
Loading…
Reference in New Issue
Block a user