Initial commit
Basic roles for installing podman, creating containers, networks and services
This commit is contained in:
16
roles/container/tasks/main.yaml
Normal file
16
roles/container/tasks/main.yaml
Normal file
@@ -0,0 +1,16 @@
|
||||
---
|
||||
- name: Create networks for container {{ container_name }}
|
||||
ansible.builtin.include_role:
|
||||
name: network
|
||||
vars:
|
||||
network_name: "{{ network }}"
|
||||
loop: "{{ container_networks }}"
|
||||
loop_control:
|
||||
loop_var: network
|
||||
|
||||
- name: Create container service {{ container_name }}
|
||||
ansible.builtin.template:
|
||||
src: container.j2
|
||||
dest: "/etc/containers/systemd/{{ container_name }}.container"
|
||||
mode: "0600"
|
||||
notify: "Restart container service {{ container_name }}"
|
||||
Reference in New Issue
Block a user