First Commit

This commit is contained in:
madereddy
2023-12-11 14:06:37 -05:00
commit e8648367dd
11 changed files with 439 additions and 0 deletions
+22
View File
@@ -0,0 +1,22 @@
- name: Build OCI Stack
hosts: Docker
tasks:
- name: Clone repo
command: wget http://192.168.1.157:3000/jeet/OCI_Build.git
- name: Start container using Docker Compose
ansible.builtin.command:
cmd: docker compose up -d
chdir: ~/docker
ignore_errors: yes
- name: Pause for 30 seconds to allow containers to stabilize
ansible.builtin.pause:
seconds: 60
- name: Check container status
ansible.builtin.shell: docker compose ps -q | xargs -n1 docker container inspect --format '{{ "{{" }} .State.Running {{ "}}" }}'
args:
chdir: ~/firstContainer
register: container_status
ignore_errors: yes