This commit is contained in:
23
ansible/deploy.yml
Normal file
23
ansible/deploy.yml
Normal file
@@ -0,0 +1,23 @@
|
||||
- hosts: servers
|
||||
become: yes
|
||||
tasks:
|
||||
- name: Install Docker
|
||||
shell: curl -fsSL https://get.docker.com | sh
|
||||
args:
|
||||
creates: /usr/bin/docker
|
||||
|
||||
- name: Install git
|
||||
apt:
|
||||
name: git
|
||||
state: present
|
||||
update_cache: yes
|
||||
|
||||
- name: Clone repo
|
||||
git:
|
||||
repo: ${GITEA_INSTANCE_URL} //как то передавать переменные
|
||||
dest: /opt/infra
|
||||
|
||||
- name: Start docker compose
|
||||
shell: docker compose up -d
|
||||
args:
|
||||
chdir: /opt/infra
|
||||
Reference in New Issue
Block a user