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

[BUG] Error running upgrade on a 0.3 cluster: missing shared-config #1491

Closed
przemyslavic opened this issue Jul 27, 2020 · 3 comments
Closed
Assignees
Labels
Milestone

Comments

@przemyslavic
Copy link
Collaborator

Describe the bug
When trying to upgrade a 0.3 cluster to develop, the user should receive a message that this type of upgrade is not supported (according to PR #1476). In fact epiphany throws an error right after running the command epicli upgrade because of missing shared-config in the manifest file.

To Reproduce
Steps to reproduce the behavior:

  1. Deploy a 0.3 cluster using image epiphanyplatform/epicli:0.3.1
  2. Execute epicli upgrade -b /path/to/build/dir from develop branch

Expected behavior
The upgrade aborts with the message Your Kubernetes version ({{ cluster_version }}) is not supported by this version of Epiphany which requires at least version 1.14.6 (Epiphany v0.4.4). For more information, refer to the documentation. because the assertion was not satisfied.

Actual behavior
Epicli fails with ERROR epicli - Expected one element but received: 0

OS (please complete the following information):

  • OS: [all]

Cloud Environment (please complete the following information):

  • Cloud Provider [all]

Additional context
Debug log:

13:16:28 ERROR epicli - Expected one element but received: 0
Traceback (most recent call last):
  File "/usr/local/lib/python3.7/site-packages/cli/epicli.py", line 127, in main
    return args.func(args)
  File "/usr/local/lib/python3.7/site-packages/cli/epicli.py", line 227, in run_upgrade
    return engine.upgrade()
  File "/usr/local/lib/python3.7/site-packages/cli/engine/UpgradeEngine.py", line 54, in upgrade
    ansible_runner.upgrade()
  File "/usr/local/lib/python3.7/site-packages/cli/engine/ansible/AnsibleRunner.py", line 137, in upgrade
    ansible_vars_generator.generate()
  File "/usr/local/lib/python3.7/site-packages/cli/engine/ansible/AnsibleVarsGenerator.py", line 74, in generate
    self.populate_group_vars(ansible_dir)
  File "/usr/local/lib/python3.7/site-packages/cli/engine/ansible/AnsibleVarsGenerator.py", line 99, in populate_group_vars
    shared_config_doc = self.get_shared_config_from_manifest()
  File "/usr/local/lib/python3.7/site-packages/cli/engine/ansible/AnsibleVarsGenerator.py", line 149, in get_shared_config_from_manifest
    shared_config_doc = select_single(manifest_docs, lambda x: x.kind == 'configuration/shared-config')
  File "/usr/local/lib/python3.7/site-packages/cli/helpers/doc_list_helpers.py", line 31, in select_single
    raise ExpectedSingleResultException("Expected one element but received: " + str(elements_count))
cli.helpers.doc_list_helpers.ExpectedSingleResultException: Expected one element but received: 0
@mkyc
Copy link
Contributor

mkyc commented Jul 29, 2020

@toszo can you get information if we know about any 0.3 cluster existing out there in the wild?

@mkyc
Copy link
Contributor

mkyc commented Aug 4, 2020

@przemyslavic there are such clusters.

@przemyslavic
Copy link
Collaborator Author

The fix has been tested. The error described above no longer occurs.

@mkyc mkyc closed this as completed Aug 27, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

4 participants