openstack internal addresses used, api-endpoints not consulted
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
juju-deployer |
Fix Released
|
Undecided
|
David Britton | ||
python-jujuclient |
Fix Released
|
Undecided
|
Unassigned |
Bug Description
The internal address returned by juju status may not be reachable. Could you instead look at juju api-endpoints and try all the ones in there? Especially given the endpoint can now be multiple addresses, the idea of using node 0 only doesn't seem right.
BTW, this is further exacerbated by the following bug in the nova provider: lp:1348287
### juju status output
machines:
"0":
agent-state: pending
agent-version: 1.20.3
dns-name: 10.10.0.2
instance-id: f4663fb3-
series: precise
hardware: arch=amd64 cpu-cores=1 mem=2048M root-disk=20480M
state-
services: {}
### juju api-endpoints output
10.96.200.201:17070
### deployer -vd output
2014-08-07 20:38:40 Creating storage deployer.yaml file
2014-08-07 20:38:40 Running juju-deployer
2014-08-07 20:38:40 [DEBUG] deployer.cli: Using runtime GoEnvironment on lsci-cloud
2014-08-07 20:38:40 [INFO] deployer.cli: Starting deployment of storage-test
2014-08-07 20:38:40 [DEBUG] deployer.import: Getting charms...
2014-08-07 20:38:40 [DEBUG] deployer.charm: Cache dir build/jenkins/
2014-08-07 20:38:41 [DEBUG] deployer.charm: Retrieving store charm cs:precise/
2014-08-07 20:38:42 [DEBUG] deployer.charm: Cache dir build/jenkins/
2014-08-07 20:38:42 [DEBUG] deployer.charm: Retrieving store charm cs:precise/
2014-08-07 20:38:42 [DEBUG] deployer.charm: Cache dir build/jenkins/
2014-08-07 20:38:43 [DEBUG] deployer.charm: Retrieving store charm cs:~davidpbritt
2014-08-07 20:38:43 [DEBUG] deployer.deploy: Resolving configuration
### strace
ubuntu@
sudo: unable to resolve host ubuntu-
Process 5669 attached
connect(3, {sa_family=AF_INET, sin_port=
Related branches
- juju-deployers: Pending requested
-
Diff: 230 lines (+145/-4)4 files modifieddeployer/env/go.py (+24/-4)
deployer/tests/test_goenv.py (+85/-0)
deployer/tests/test_utils.py (+22/-0)
deployer/utils.py (+14/-0)
Changed in juju-deployer: | |
status: | New → Confirmed |
Changed in juju-deployer: | |
status: | Confirmed → In Progress |
assignee: | nobody → David Britton (davidpbritton) |
Changed in juju-deployer: | |
milestone: | none → 0.4.0 |
Changed in python-jujuclient: | |
status: | New → Fix Released |
Changed in juju-deployer: | |
status: | In Progress → Fix Committed |
Changed in juju-deployer: | |
status: | Fix Committed → Fix Released |
Here is a simple a simple patch that allows this to be overridden for testing purposes (you can pass in the full wss://<host>:port url to that --endpoint option), I'm not suggesting that is the right fix.
### "patch" for a workaround.
ubuntu@ ubuntu- local-machine- 1:/usr/ lib/python2. 7/dist- packages/ deployer$ diff env/go.orig.py env/go.py ubuntu- local-machine- 1:/usr/ lib/python2. 7/dist- packages/ deployer$ diff cli.orig.py cli.py add_argument(
27c27
< self.api_endpoint = endpoint
---
> self.api_endpoint = options.endpoint
ubuntu@
117a118,119
> parser.
> '--endpoint', action='store', dest='endpoint')