mirror of
https://github.com/Websoft9/websoft9.git
synced 2025-01-24 10:17:15 +08:00
28 lines
989 B
YAML
28 lines
989 B
YAML
- name: Create credentials Folder
|
|
file:
|
|
path: /credentials
|
|
state: directory
|
|
|
|
- name: Create credentials Folder
|
|
file:
|
|
path: /data/apps/{{appname}}
|
|
state: directory
|
|
|
|
- name: Save .env and init_without_docker.sh
|
|
shell : |
|
|
wget -N https://raw.githubusercontent.com/Websoft9/StackHub/main/apps/roles/{{appname}}/templates/.env -O /data/apps/{{appname}}/.env
|
|
wget -N https://raw.githubusercontent.com/Websoft9/StackHub/main/apps/roles/{{appname}}/templates/init_without_docker.sh -O /data/apps/{{appname}}/init_without_docker.sh
|
|
|
|
- name: Excute Preparation if have pre.yml
|
|
block:
|
|
- name: Check if pre.yml exists
|
|
uri:
|
|
url: "https://github.com/Websoft9/StackHub/blob/main/apps/roles/{{appname}}/tasks/pre.yml"
|
|
return_content: yes
|
|
register: pre_exists
|
|
failed_when: false
|
|
|
|
- name: Excute pre.yml
|
|
include_tasks: roles/{{appname}}/tasks/pre.yml
|
|
when: pre_exists.status is defined and pre_exists.status == 200
|