Skip to content

Commit

Permalink
Move podman socket activation to podman role
Browse files Browse the repository at this point in the history
The expectation was that the podman role would fully configure the
podman service, but we needed to run the podman_sdk role for socket
activation to be enabled.

It also meant that you needed to run the podman_sdk role after the
podman role (as it expected that podman was already installed) which is
not always desirable. For instance, in kayobe, we setup the virtualenv
before configuring the container engine.

Closes-Bug: #2054568
Change-Id: Ic9d3cf9ad94f0cb28f9f1073ff02842a38211a54
  • Loading branch information
jovial committed Feb 21, 2024
1 parent dbb7d9c commit 70f3a39
Show file tree
Hide file tree
Showing 3 changed files with 18 additions and 7 deletions.
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
---
upgrade:
- |
Socket activation of podman is now enabled by the ``podman`` role and
not the ``podman_sdk`` role.
fixes:
- |
Fixes an issue where the ``podman`` role did not enable socket activation
for the podman service.
See `LP#2054568 <https://bugs.launchpad.net/ansible-collection-kolla/+bug/2054568>`__
for further details.
7 changes: 7 additions & 0 deletions roles/podman/tasks/install.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,13 @@
# If any packages were updated, and any containers were running, wait for the
# daemon to come up and start all previously running containers.

- name: Start podman.socket
become: true
service:
name: podman.socket
state: started
enabled: yes

- block:
- name: Wait for Podman to start
command: podman info
Expand Down
7 changes: 0 additions & 7 deletions roles/podman_sdk/tasks/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -61,10 +61,3 @@
become: true
become_user: "{{ virtualenv is none | ternary(omit, podman_sdk_virtualenv_owner) }}"
when: not (ansible_facts.distribution_release == "bookworm" and virtualenv is none)

- name: Start podman.socket
become: true
service:
name: podman.socket
state: started
enabled: yes

0 comments on commit 70f3a39

Please sign in to comment.