mirror of
https://github.com/Websoft9/websoft9.git
synced 2025-01-24 10:17:15 +08:00
Update application.yml
This commit is contained in:
parent
6f80fdf1f0
commit
df59c9958d
@ -5,8 +5,6 @@
|
|||||||
|
|
||||||
vars_files:
|
vars_files:
|
||||||
- vars/main.yml
|
- vars/main.yml
|
||||||
- roles/{{appname}}/vars/main.yml
|
|
||||||
- roles/{{appname}}/defaults/main.yml
|
|
||||||
|
|
||||||
pre_tasks:
|
pre_tasks:
|
||||||
- name: Excute base roles for apps
|
- name: Excute base roles for apps
|
||||||
@ -17,46 +15,6 @@
|
|||||||
with_items:
|
with_items:
|
||||||
- role_common
|
- role_common
|
||||||
- role_cloud
|
- role_cloud
|
||||||
|
|
||||||
- name: Git Clone app docker repository
|
|
||||||
block:
|
|
||||||
- name: Create app directory
|
|
||||||
shell: mkdir -p {{installpath}}
|
|
||||||
- name: Delete {{appname}} dir for sec_installation
|
|
||||||
shell: rm -rf {{installpath}}/{{appname}}
|
|
||||||
- name: Clone {{appname}} in Websoft9
|
|
||||||
git:
|
|
||||||
repo: "https://github.com/Websoft9/docker-{{appname}}.git"
|
|
||||||
dest: "{{installpath}}/{{appname}}"
|
|
||||||
|
|
||||||
- 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
|
|
||||||
|
|
||||||
- name: Install {{appname}}
|
|
||||||
include_tasks: tasks/install.yml
|
|
||||||
vars:
|
|
||||||
app: "{{item}}"
|
|
||||||
loop: "{{applist}}"
|
|
||||||
|
|
||||||
- name: Check Docker Container Service
|
|
||||||
shell: docker ps --format \{\{'json .'\}\}| jq -s map\(\{containername:'.Names',state:'.State'\}\)
|
|
||||||
register: check_container_service
|
|
||||||
notify: check_container_service
|
|
||||||
|
|
||||||
handlers:
|
|
||||||
- name: check_container_service
|
|
||||||
debug:
|
|
||||||
var: check_container_service.stdout
|
|
||||||
|
|
||||||
roles:
|
roles:
|
||||||
- { role: role_nginx, tags: "role_nginx" }
|
- { role: role_nginx, tags: "role_nginx" }
|
||||||
|
Loading…
Reference in New Issue
Block a user