Add image role, support logging in to registries

This commit is contained in:
uumas
2025-04-10 19:27:16 +03:00
parent 093e7846ad
commit 3ac6b98a30
11 changed files with 105 additions and 5 deletions

View File

@@ -2,6 +2,14 @@
- name: Validate inputs
ansible.builtin.import_tasks: validation.yaml
- name: Create image for container {{ container_name }}
ansible.builtin.include_role:
name: image
vars:
image_name: "{{ container_image }}"
image_creds: "{{ container_image_creds }}"
when: image_created_images is not defined or container_image not in image_created_images
- name: Create networks for container {{ container_name }}
ansible.builtin.include_role:
name: network
@@ -29,7 +37,7 @@
- name: Create container service {{ container_name }}
containers.podman.podman_container:
image: "{{ container_image }}"
image: "{{ _container_image }}"
name: "{{ container_name }}"
command: "{{ container_command or omit }}"
user: "{{ container_user or omit }}"