ansible-edda/playbooks/roles/services/setup/user/tasks/include/podman.yml

23 lines
808 B
YAML
Raw Normal View History

2022-12-18 23:43:40 +01:00
---
2022-12-11 00:41:50 +01:00
- block:
2022-12-12 23:49:20 +01:00
- name: "{{ services_service_name }} : podman : create container configuration directory"
2022-12-11 00:41:50 +01:00
ansible.builtin.file:
path: "{{ services_service_user_home }}/.config/containers"
state: "directory"
mode: 0755
2022-12-12 23:49:20 +01:00
- name: "{{ services_service_name }} : podman : configure podman storage"
2022-12-11 00:41:50 +01:00
ansible.builtin.template:
2022-12-12 23:49:20 +01:00
src: "./podman/storage.conf.j2"
2022-12-11 00:41:50 +01:00
dest: "{{ services_service_user_home }}/.config/containers/storage.conf"
mode: 0644
register: services_setup_user_containers_storage
2022-12-11 00:41:50 +01:00
2022-12-12 23:49:20 +01:00
- name: "{{ services_service_name }} : podman : reset podman"
2022-12-11 00:41:50 +01:00
ansible.builtin.shell: "cd $HOME; yes | podman system reset"
when:
services_setup_user_containers_storage.changed
2022-12-11 00:41:50 +01:00
become_user: "{{ services_service_user_name }}"