Add registry login.
This commit is contained in:
parent
e743ecea47
commit
2f3caee853
@ -14,6 +14,23 @@
|
|||||||
|
|
||||||
- debug: var=commit
|
- debug: var=commit
|
||||||
|
|
||||||
|
# podman logout is needed before podman login if registry was recreated
|
||||||
|
- name: Logout from registry
|
||||||
|
containers.podman.podman_logout:
|
||||||
|
registry: "{{ image.push_dest }}"
|
||||||
|
changed_when: false
|
||||||
|
become: true
|
||||||
|
when: image.push | default(False) | bool
|
||||||
|
|
||||||
|
- name: Login to registry and create ${XDG_RUNTIME_DIR}/containers/auth.json
|
||||||
|
containers.podman.podman_login:
|
||||||
|
username: "{{ image.push_user }}"
|
||||||
|
password: "{{ image.push_pwd }}"
|
||||||
|
registry: "{{ image.push_dest }}"
|
||||||
|
changed_when: false
|
||||||
|
become: true
|
||||||
|
when: image.push | default(False) | bool
|
||||||
|
|
||||||
- name: Build {{ image.name }} image
|
- name: Build {{ image.name }} image
|
||||||
containers.podman.podman_image:
|
containers.podman.podman_image:
|
||||||
name: "{{ image.name }}:{{ commit }}"
|
name: "{{ image.name }}:{{ commit }}"
|
||||||
|
Loading…
Reference in New Issue
Block a user