my-containers/build_generic_images.yaml

45 lines
1.1 KiB
YAML
Raw Normal View History

2024-11-02 03:56:53 +01:00
- name: Build generic containers - base python and ci
hosts: localhost
gather_facts: false
vars:
force: false
force_rm: false
cache: false
registry: code.philo.ydns.eu
organisation: philorg
2024-11-02 03:56:53 +01:00
tasks:
- name: Using the variables
ansible.builtin.debug:
var: force_rm
- name: Build the base image (trixie_python)
2024-11-02 03:56:53 +01:00
containers.podman.podman_image:
name: trixie_python
state: build
path: "{{ playbook_dir }}"
tag: 1
build:
format: oci
force_rm: "{{ force_rm }}"
cache: "{{ cache }}"
file: Containerfile.trixie_python
push: true
push_args:
dest: "{{ registry }}/{{ organisation }}/trixie_python"
2024-11-02 03:56:53 +01:00
- name: Build the image for ci
containers.podman.podman_image:
name: python-ci
state: build
path: "{{ playbook_dir }}"
tag: 1
build:
format: oci
force_rm: "{{ force_rm }}"
cache: "{{ cache }}"
file: Containerfile.ci
push: true
push_args:
dest: "{{ registry }}/{{ organisation }}/python-ci"