Juju might not be recognzing some OpenStack environment variables (see comments)

Bug #1806985 reported by Michael Skalka
34
This bug affects 6 people
Affects Status Importance Assigned to Milestone
Canonical Juju
Won't Fix
High
Unassigned
2.5
Won't Fix
High
Unassigned
2.6
Won't Fix
High
Unassigned

Bug Description

When bootstrapping a Juju controller against and existing OpenStack cloud if the 'domain-name' field is set in credentials.yaml the bootstrap fails with the following error:

ubuntu@OrangeBox68:~$ juju bootstrap test-stack --bootstrap-series xenial --config external-network=ext-net --config network=int-net --config use-floating-ip=true --metadata-source /home/ubuntu/simplestreams
Creating Juju controller "test-stack-RegionOne" on test-stack/RegionOne
Looking for packaged Juju agent version 2.5-rc1 for amd64
No packaged binary found, preparing local Juju agent binary
Launching controller instance(s) on test-stack/RegionOne...
ERROR failed to bootstrap model: cannot start bootstrap instance: cannot set up groups: failed to create a security group with name: juju-c0f8b1f0-0de4-4b3f-85fc-64abf0c5781a-4776d32b-0d68-446b-86f5-e77c17d0f616
caused by: request (http://172.27.69.80:9696/v2.0/security-groups) returned unexpected status: 400; error info: {"NeutronError": {"message": "Running without keystone AuthN requires that tenant_id is specified", "type": "HTTPBadRequest", "detail": ""}}

This was reproduced in both 2.5-rc1 and latest stable (2.4.7). Setting this field in credentials.yaml to "" results in a successful bootstrap.

Michael Skalka (mskalka)
description: updated
tags: added: cpe-onsite
Changed in juju:
status: New → Triaged
Revision history for this message
Richard Harding (rharding) wrote :

This might also tie into https://bugs.launchpad.net/juju/+bug/1772649 though they're slightly different with one being around autoload-credentials.

Changed in juju:
importance: Undecided → High
milestone: none → 2.5.0
milestone: 2.5.0 → 2.5.1
Ian Booth (wallyworld)
Changed in juju:
milestone: 2.5.1 → 2.5.2
Changed in juju:
milestone: 2.5.2 → 2.5.3
Changed in juju:
milestone: 2.5.3 → 2.5.4
Changed in juju:
milestone: 2.5.4 → 2.5.5
Changed in juju:
milestone: 2.5.6 → 2.5.8
Revision history for this message
Fabrizio Cardarello (f.cardarello) wrote :

After a few try those are the right option: juju version 2.6.2
credentials:
  cloud-openstack:
    default-region: RegionOne
    test:
      auth-type: userpass
      domain-name: ''
      password: password
      project-domain-name: admin_domain
      tenant-id: 8650020e13774c0aaa73e1e173ce8adf
      tenant-name: kubernetes
      user-domain-name: admin_domain
      username: admin
      version: "3"

Changed in juju:
milestone: 2.5.8 → none
milestone: none → 2.7-beta1
Revision history for this message
Tim McNamara (tim-clicks) wrote :

This bug has been referenced by a discourse post, where another workaround has been found:

https://discourse.jujucharms.com/t/1628/3?u=timclicks

Revision history for this message
Heather Lanigan (hmlanigan) wrote :
Changed in juju:
milestone: 2.7-beta1 → 2.7-rc1
Revision history for this message
Anastasia (anastasia-macmood) wrote :

Removing from a milestone as this work will not be done in 2.5 nor 2.6 series.

Changed in juju:
milestone: 2.7-rc1 → none
milestone: none → 2.7.1
Changed in juju:
milestone: 2.7.1 → 2.7.2
Changed in juju:
milestone: 2.7.2 → 2.7.3
Changed in juju:
milestone: 2.7.3 → 2.7.4
Changed in juju:
milestone: 2.7.4 → 2.7.5
Changed in juju:
milestone: 2.7.5 → 2.7.6
Ian Booth (wallyworld)
Changed in juju:
milestone: 2.7.6 → 2.9-beta1
milestone: 2.9-beta1 → 2.8.1
Pen Gale (pengale)
Changed in juju:
milestone: 2.8.1 → none
Tim Penhey (thumper)
tags: added: openstack-provider
Revision history for this message
Adam Dyess (addyess) wrote :

Using the 2.8.6 snap installed client. We confirmed the OS_PROJECT_ID environment variable was set, so when bootstrapping, we didn't fill in the 'tenant_id' or 'tenant_name' options.

Because we didn't fill them in, the juju client picked the user's default project id from openstack rather than the one in the environment variables and tried to bootstrap the controller in the wrong project.

I think this bug is probably the closest relative because something isn't quite right with reading the OS_* environment variables.

Revision history for this message
Pen Gale (pengale) wrote :

I think that the Juju client might be lagging behind OpenStack in terms of which environment variables it pays attention to. We should audit the client and update it as necessary.

summary: - Juju fails to bootstrap on OpenStack with 'domain-name' set in
- credentials.yaml
+ Juju might not be recognzing some OpenStack environment variables
summary: - Juju might not be recognzing some OpenStack environment variables
+ Juju might not be recognzing some OpenStack environment variables (see
+ comments)
Changed in juju:
milestone: none → 3.0.0
Changed in juju:
milestone: 3.0.0 → 3.0.1
Changed in juju:
milestone: 3.0.1 → 3.0.2
Changed in juju:
milestone: 3.0.2 → 3.0.3
Revision history for this message
Juan M. Tirado (tiradojm) wrote :

Please reopen if the issue persists.

Changed in juju:
status: Triaged → Won't Fix
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Duplicates of this bug

Other bug subscribers

Remote bug watches

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