2b37cf7a9e
Per https://github.com/containers/podman-compose/issues/209 it seems this is a known thing with non root containers, podman, and Ubuntu. Just apply the necessary woraround in a config file so that we don't have to be aware of it every time we try to use podman in this way. It also makes using podman-compose simpler. Change-Id: Ic024e242d99b7f0d4fbd4cf2c3489022b364672d
35 lines
878 B
YAML
35 lines
878 B
YAML
- name: Add project atomic PPA repository
|
|
include_role:
|
|
name: ensure-package-repositories
|
|
vars:
|
|
repositories_list:
|
|
- repo: ppa:projectatomic/ppa
|
|
|
|
- name: Install podman
|
|
package:
|
|
name:
|
|
- podman
|
|
- uidmap
|
|
- slirp4netns
|
|
state: present
|
|
become: yes
|
|
|
|
# NOTE(pabelanger): Remove default registries.conf file, so we can manage it
|
|
# ourself. It could have v1 syntax, which doesn't work with v2.
|
|
- name: Remove /etc/containers/registries.conf
|
|
become: true
|
|
file:
|
|
state: absent
|
|
path: /etc/containers/registries.conf
|
|
|
|
- name: Create containers config dir
|
|
file:
|
|
path: '{{ ansible_user_dir }}/.config/containers'
|
|
state: directory
|
|
- name: Force cgroup manager to cgroupfs for Ubuntu
|
|
copy:
|
|
content: |
|
|
[engine]
|
|
cgroup_manager = "cgroupfs"
|
|
dest: '{{ ansible_user_dir }}/.config/containers/containers.conf'
|