Error cluster-config with Openstack Rocky

Bug #1807104 reported by Adrien Fontaine
10
This bug affects 2 people
Affects Status Importance Assigned to Milestone
python-magnumclient
Invalid
Undecided
Adrien Fontaine

Bug Description

I get an error when trying to get a K8s cluster configuration on an Openstack Rocky cloud.

With python-magnumclient 2.11.0 and python 2.7.15 :

magnum cluster-config <cluster_name>

Traceback (most recent call last):
  File "/usr/local/lib/python2.7/site-packages/magnumclient/shell.py", line 640, in main
    OpenStackMagnumShell().main(map(encodeutils.safe_decode, sys.argv[1:]))
  File "/usr/local/lib/python2.7/site-packages/magnumclient/shell.py", line 552, in main
    args.func(self.cs, args)
  File "<decorator-gen-142>", line 2, in do_cluster_config
  File "/usr/local/lib/python2.7/site-packages/magnumclient/common/cliutils.py", line 140, in wrapper
    return func(*args, **kwargs)
  File "/usr/local/lib/python2.7/site-packages/magnumclient/v1/clusters_shell.py", line 288, in do_cluster_config
    cfg_dir=args.dir, force=args.force))
  File "/usr/local/lib/python2.7/site-packages/magnumclient/common/utils.py", line 167, in config_cluster
    force, certs)
  File "/usr/local/lib/python2.7/site-packages/magnumclient/common/utils.py", line 227, in _config_cluster_kubernetes
    if 'csh' in os.environ['SHELL']:
  File "/usr/local/lib/python2.7/UserDict.py", line 40, in __getitem__
    raise KeyError(key)
KeyError: 'SHELL'
ERROR: 'SHELL'

With python-magnumclient 2.11.0 and python 3.7.1 :

magnum cluster-config <cluster_name>

Traceback (most recent call last):
  File "/usr/local/lib/python3.7/site-packages/magnumclient/shell.py", line 640, in main
    OpenStackMagnumShell().main(map(encodeutils.safe_decode, sys.argv[1:]))
  File "/usr/local/lib/python3.7/site-packages/magnumclient/shell.py", line 552, in main
    args.func(self.cs, args)
  File "<decorator-gen-142>", line 2, in do_cluster_config
  File "/usr/local/lib/python3.7/site-packages/magnumclient/common/cliutils.py", line 140, in wrapper
    return func(*args, **kwargs)
  File "/usr/local/lib/python3.7/site-packages/magnumclient/v1/clusters_shell.py", line 288, in do_cluster_config
    cfg_dir=args.dir, force=args.force))
  File "/usr/local/lib/python3.7/site-packages/magnumclient/common/utils.py", line 167, in config_cluster
    force, certs)
  File "/usr/local/lib/python3.7/site-packages/magnumclient/common/utils.py", line 227, in _config_cluster_kubernetes
    if 'csh' in os.environ['SHELL']:
  File "/usr/local/lib/python3.7/os.py", line 678, in __getitem__
    raise KeyError(key) from None
KeyError: 'SHELL'
ERROR: b"'SHELL'"

With python-openstackclient 3.17.0 and python 3.6.4 :

openstack coe cluster config <cluster_name>

a bytes-like object is required, not 'str'
clean_up ConfigCluster: a bytes-like object is required, not 'str'

I can give more information if necessary.

information type: Public → Public Security
information type: Public Security → Private
information type: Private → Public
Changed in python-magnumclient:
assignee: nobody → Adrien Fontaine (afontaine)
status: New → Invalid
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.