cmd/juju: deploy --to a non existent machine fails too late in the process

Bug #1212538 reported by Dave Cheney
18
This bug affects 2 people
Affects Status Importance Assigned to Milestone
juju-core
Fix Released
Low
Matthew Williams

Bug Description

Juju should check earlier in the piece if the machine to hulk smash exists.

lucky(~/charms/precise/mediawiki) % juju deploy -v --to 9001 juju-gui
2013-08-15 05:25:31 INFO juju provider.go:121 environs/openstack: opening environment "nec-az3"
2013-08-15 05:25:35 INFO juju open.go:69 state: opening state; mongo addresses: ["15.185.243.11:37017"]; entity ""
2013-08-15 05:25:37 INFO juju open.go:107 state: connection established
2013-08-15 05:25:41 INFO juju conn.go:292 writing charm to storage [79337 bytes]
2013-08-15 05:25:45 INFO juju conn.go:304 adding charm to state
2013-08-15 05:26:08 ERROR juju supercommand.go:274 command failed: cannot assign unit "juju-gui/0" to machine: machine 9001 not found
error: cannot assign unit "juju-gui/0" to machine: machine 9001 not found

lucky(~/charms/precise/mediawiki) % juju deploy --to 9001 juju-gui
error: cannot add service "juju-gui": service already exists

lucky(~/charms/precise/mediawiki) % juju status
environment: nec-az3
machines:
  "0":
    agent-state: started
    agent-version: 1.13.1
    dns-name: 15.185.243.11
    instance-id: "1686545"
    series: precise
    hardware: arch=amd64 cpu-cores=1 mem=1024M
services:
  juju-gui:
    charm: cs:precise/juju-gui-74
    exposed: false
    units:
      juju-gui/0:
        agent-state: pending

John A Meinel (jameinel)
Changed in juju-core:
status: New → Triaged
Curtis Hovey (sinzui)
Changed in juju-core:
importance: Medium → Low
Curtis Hovey (sinzui)
tags: added: deploy
Changed in juju-core:
status: Triaged → In Progress
assignee: nobody → Matthew Williams (mattyw)
Revision history for this message
Matthew Williams (mattyw) wrote :

Submitted a pull request https://github.com/juju/juju/pull/268

Changed in juju-core:
status: In Progress → Fix Committed
Curtis Hovey (sinzui)
Changed in juju-core:
milestone: none → 1.21-alpha1
Curtis Hovey (sinzui)
Changed in juju-core:
status: Fix Committed → Fix Released
Martin Packman (gz)
tags: added: placement
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.