fix: add task to handle registry logouts
This commit is contained in:
parent
13672e86ab
commit
fa97e3274f
@ -16,8 +16,7 @@ podman_nsremap_range_length: 65536
|
||||
# - registry: myregistry.example.com (optional)
|
||||
# username: docker
|
||||
# password: secure
|
||||
# reauthorize: False
|
||||
# state: present
|
||||
# active: True
|
||||
# @end
|
||||
podman_registries: []
|
||||
|
||||
|
@ -52,7 +52,15 @@
|
||||
registry: "{{ item.registry }}"
|
||||
username: "{{ item.username }}"
|
||||
password: "{{ item.password }}"
|
||||
state: '{{ item.state | default("present") }}'
|
||||
when: item.active | default(True) | bool
|
||||
loop: "{{ podman_registries }}"
|
||||
loop_control:
|
||||
label: "{{ item.registry }}"
|
||||
|
||||
- name: Handle registry logouts
|
||||
containers.podman.podman_logout:
|
||||
registry: "{{ item.registry }}"
|
||||
when: not item.active | default(True) | bool
|
||||
loop: "{{ podman_registries }}"
|
||||
loop_control:
|
||||
label: "{{ item.registry }}"
|
||||
|
Loading…
Reference in New Issue
Block a user