Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

avoid the use of install-config #380

Closed
alaypatel07 opened this issue Jul 15, 2020 · 3 comments · Fixed by #421
Closed

avoid the use of install-config #380

alaypatel07 opened this issue Jul 15, 2020 · 3 comments · Fixed by #421
Assignees
Labels
1.3.0 kind/bug Categorizes issue or PR as related to a bug.

Comments

@alaypatel07
Copy link
Contributor

Back in my openshift dev days, I remember the recommendation
was to never use install-config after the cluster is installed. The
information in install config is only prevalent during install time and
can change when cluster is running.

We currently use the install config to get the apiserver URL. A more
reliable way IMHO of finding the same information would be using
the infrastructures API

[alpatel@alpatel agnosticd]$ oc get infrastructures -oyaml | grep apiServerURL -C 2
  status:
    apiServerInternalURI: https://api-int.cluster-alpatel-pvc-migrate-440.alpatel-pvc-migrate-440.mg.dog8code.com:6443
    apiServerURL: https://api.cluster-alpatel-pvc-migrate-440.alpatel-pvc-migrate-440.mg.dog8code.com:6443
    etcdDiscoveryDomain: cluster-alpatel-pvc-migrate-440.alpatel-pvc-migrate-440.mg.dog8code.com
    infrastructureName: cluster-alpatel-pvc-m-g9k4h
[alpatel@alpatel agnosticd]$
@jmontleon
Copy link
Collaborator

Thank you for investigating @alaypatel07

@alaypatel07 alaypatel07 linked a pull request Jul 15, 2020 that will close this issue
10 tasks
@jwmatthews
Copy link
Contributor

@alaypatel07++

@jmontleon jmontleon added 1.3.1 1.3.0 kind/bug Categorizes issue or PR as related to a bug. PR Posted and removed 1.3.1 labels Aug 18, 2020
@jmontleon jmontleon linked a pull request Aug 26, 2020 that will close this issue
10 tasks
@jmontleon jmontleon reopened this Aug 27, 2020
@jmontleon
Copy link
Collaborator

I had to revert the PR.

 TASK [set_fact] ******************************** 
fatal: [localhost]: FAILED! => {"msg": "The conditional check 'infrastructures is defined and infrastructures.get('resources', [{}])[0].get('status'. {}).get('apiServerURL', '') != ''' failed. The error was: template error while templating string: expected name or number. String: {% if infrastructures is defined and infrastructures.get('resources', [{}])[0].get('status'. {}).get('apiServerURL', '') != '' %} True {% else %} False {% endif %}\n\nThe error appears to be in '/opt/ansible/roles/migrationcontroller/tasks/main.yml': line 86, column 7, but may\nbe elsewhere in the file depending on the exact syntax problem.\n\nThe offending line appears to be:\n\n    block:\n    - set_fact:\n      ^ here\n"}
111

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
1.3.0 kind/bug Categorizes issue or PR as related to a bug.
Projects
None yet
3 participants