add ability to build image
Some checks failed
Deploy Containers / Prepare (push) Failing after 19s

This commit is contained in:
2025-11-19 16:44:47 -05:00
parent a8e6ed70ab
commit 31f2b51b37
2 changed files with 55 additions and 49 deletions

View File

@@ -5,6 +5,25 @@
state: directory
with_items: "{{ directories }}"
- name: Clone repository
git:
repo: "{{ build.git.repo }}"
dest: "{{ build.git.dest }}"
when: build is defined
- name: Build Docker Image
docker_image:
name: "{{ image.name }}"
tag: "{{ image.tag }}"
build:
nocache: true
path: "{{ build.git.dest }}"
dockerfile: Dockerfile
source: build
force_source: true
state: present
when: build is defined
- name: Pull latest Docker image
docker_image:
name: "{{ image.name }}"