feat: Use linux.system_roles.podman for Podman installation
This commit is contained in:
parent
dcc09732da
commit
c9ad97aace
@ -3,7 +3,12 @@
|
||||
become: true
|
||||
vars:
|
||||
ansible_python_interpreter: /usr/bin/python3
|
||||
pre_tasks:
|
||||
- name: Install linux.system_roles collection
|
||||
ansible.builtin.command: ansible-galaxy collection install linux.system_roles
|
||||
args:
|
||||
creates: ~/.ansible/collections/ansible_collections/linux/system_roles
|
||||
roles:
|
||||
- common
|
||||
- podman # Ensure podman is configured before network
|
||||
- network
|
||||
- linux.system_roles.podman # Use the new podman role
|
||||
- network
|
||||
|
||||
@ -1,34 +0,0 @@
|
||||
---
|
||||
- name: Install Podman
|
||||
ansible.builtin.apt:
|
||||
name: podman
|
||||
state: present
|
||||
|
||||
- name: Install python3-pip
|
||||
ansible.builtin.apt:
|
||||
name: python3-pip
|
||||
state: present
|
||||
|
||||
- name: Install podman-compose
|
||||
ansible.builtin.pip:
|
||||
name: podman-compose
|
||||
state: present
|
||||
|
||||
- name: Install podman-docker (optional, for docker command alias)
|
||||
ansible.builtin.apt:
|
||||
name: podman-docker
|
||||
state: present
|
||||
|
||||
- name: Configure unqualified image search registries for Podman
|
||||
ansible.builtin.copy:
|
||||
src: registries.conf.j2
|
||||
dest: /etc/containers/registries.conf
|
||||
owner: root
|
||||
group: root
|
||||
mode: '0644'
|
||||
become: true
|
||||
|
||||
- name: Install containers.podman collection
|
||||
ansible.builtin.command: ansible-galaxy collection install containers.podman
|
||||
args:
|
||||
creates: ~/.ansible/collections/ansible_collections/containers/podman
|
||||
@ -1,5 +0,0 @@
|
||||
# This file is a template for /etc/containers/registries.conf
|
||||
# It configures unqualified image search registries for Podman.
|
||||
|
||||
[registries.search]
|
||||
registries = ['docker.io', 'registry.access.redhat.com', 'registry.redhat.io']
|
||||
Loading…
x
Reference in New Issue
Block a user