Skip to content

Commit dc72a2c

Browse files
committed
[devscripts] Restore pull-secret when PreMetal was used
On executing reproducer playbook which is triggering devscripts role, if the var: mirror_images is not true, the pull secret restore is skipped. In some cases, there is overwrite devscripts config vars like: cifmw_devscripts_config_overrides: mirror_images: true When the PreMetal (earlier ZIronic) is used, pull-secret restore should be done each time to avoid potential issues, like: - 'task path: /home/zuul/src/github.com/openstack-k8s-operators/ci-framework/roles/kustomize_deploy/tasks/install_operators.yml:171' - 'fatal: [localhost]: FAILED! => ' - ' changed: false' - ' msg: |' - ' Subscription resolution failed for openstack-operator!' - '' - ' Reason: ErrorPreventedResolution' - ' Message: error using catalogsource openshift-marketplace/community-operators: failed to list bundles: rpc error: code = Unavailable desc = connection error: desc = "transport: Error while dialing: dial tcp 172.30.172.219:50051: connect: connection refused"' Signed-off-by: Daniel Pawlik <dpawlik@redhat.com>
1 parent 8b3b055 commit dc72a2c

1 file changed

Lines changed: 4 additions & 3 deletions

File tree

roles/devscripts/tasks/300_post.yml

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -26,9 +26,10 @@
2626
- not cifmw_devscripts_ocp_online | bool
2727
ansible.builtin.import_tasks: set_cluster_fact.yml
2828

29-
- name: Restore pull-secret if mirror_images is enabled
30-
when:
31-
- cifmw_devscripts_config.mirror_images | default(false) | bool
29+
- name: Restore pull-secret if mirror_images is enabled or bootstrapped with PreMetal
30+
when: >
31+
(cifmw_devscripts_config.mirror_images | default(false) | bool) or
32+
(cifmw_deploy_reproducer_env | default(false) | bool)
3233
tags:
3334
- devscripts_deploy
3435
ansible.builtin.include_tasks: 320_restore_pull_secret.yml

0 commit comments

Comments
 (0)