migrate_default_registry_var.yml 670 B

12345678910111213141516171819202122
  1. ---
  2. # This work is to migrate the OPENSHIFT_DEFAULT_REGISTRY variable
  3. # inside of the docker-registry's dc to REGISTRY_OPENSHIFT_SERVER_ADDR
  4. - name: migrate docker registry env var
  5. oc_edit:
  6. kind: dc
  7. name: "{{ openshift_hosted_registry_name }}"
  8. namespace: "{{ openshift_hosted_registry_namespace }}"
  9. edits:
  10. - action: update
  11. key: spec.template.spec.containers[0].env
  12. value:
  13. name: REGISTRY_OPENSHIFT_SERVER_ADDR
  14. value: docker-registry.default.svc:5000
  15. curr_value:
  16. name: OPENSHIFT_DEFAULT_REGISTRY
  17. value: docker-registry.default.svc:5000
  18. register: editout
  19. - debug:
  20. var: editout
  21. verbosity: 1