levonet.ci_registry_rm_container
CI: Remove Docker Container from Registry
This role is helpful in the CI pipeline after finishing a Pull Request and cleaning up resources.
Role Variables
ci_registry_scheme
(default: http)ci_registry_url
(default: localhost): The URL for the Registry API.ci_registry_container
(required): The name of the container.ci_registry_tag
(required): The tag for the container.ci_registry_username
(optional): Username for the registry.ci_registry_password
(optional): Password for the registry.
Example Playbook
- hosts: 127.0.0.1
connection: local
gather_facts: no
vars:
ci_registry_url: registry.myorg.com
ci_registry_container: myorg/myapp
ci_registry_tag: "{{ myapp_tag }}"
roles:
- role: levonet.registry-rm-container
To run in Jenkins:
ansible-playbook myplaybook.yml -e myapp_tag="${GIT_BRANCH}"
License
Author Information
This role was created by Pavlo Bashynskyi
Installa
ansible-galaxy install levonet.ci_registry_rm_container
Licenza
mit
Download
8.1k
Proprietario