diff --git a/deployment/ansible/playbooks/deploy-update.yml b/deployment/ansible/playbooks/deploy-update.yml index 342e6c98..72dba1f8 100644 --- a/deployment/ansible/playbooks/deploy-update.yml +++ b/deployment/ansible/playbooks/deploy-update.yml @@ -126,7 +126,8 @@ - name: Update docker-compose.yml with new image tag (all services) replace: path: "{{ app_stack_path }}/docker-compose.yml" - regexp: '^(\s+image:\s+){{ app_image }}:.*$' + # Match both localhost:5000 and git.michaelschiemer.de:5000 (or any registry URL) + regexp: '^(\s+image:\s+)(localhost:5000|git\.michaelschiemer\.de:5000|{{ docker_registry }})/{{ app_name }}:.*$' replace: '\1{{ app_image }}:{{ image_tag }}' when: image_pull.changed or image_tag != 'latest' register: compose_updated