Merge lp:~fwereade/pyjuju/orchestra-series-constraints into lp:pyjuju

Proposed by William Reade
Status: Merged
Approved by: Kapil Thangavelu
Approved revision: 525
Merged at revision: 527
Proposed branch: lp:~fwereade/pyjuju/orchestra-series-constraints
Merge into: lp:pyjuju
Diff against target: 0 lines
To merge this branch: bzr merge lp:~fwereade/pyjuju/orchestra-series-constraints
Reviewer Review Type Date Requested Status
Juju Engineering Pending
Review via email: mp+101670@code.launchpad.net

Description of the change

orchestra provider now respects ubuntu-series constraint

This is done by setting a new system profile before powering on the machine;
and assumes that the Cobbler system profiles created as part of the
ubuntu-orchestra-server install actually exist. Anecdotal evidence suggests
that people really don't mess with the distros and profiles available (they
just set up their systems and go) and so I consider the impact of this
drawback to be extremely limited.

Furthermore, while it is possible to extract real arch and series info from
cobbler (ie we can get a system's arch from its profile's distro, and we can
partially match new profiles by checking the distro's series and arch) this
is not enough to select an actual profile without depending on some
convention: we either have to infer the presence of the juju preseed from
the profile name (as I do currently) or to check the profile itself for
a magic string (ie the path to the juju preseed).

So: we depend on orchestra install conventions, whatever we do; and IMO it's
cleanest and simplest to actually embrace that and save all the mucking
about with distros and profiles.

https://codereview.appspot.com/6012045/

To post a comment you must log in.
Revision history for this message
William Reade (fwereade) wrote :

Reviewers: mp+101670_code.launchpad.net,

Message:
Please take a look.

Description:
orchestra provider now respects ubuntu-series constraint

This is done by setting a new system profile before powering on the
machine;
the only wrinkle is that the only way to detect the machine's actual
arch is
by inferring it from the original system profile.

This assumes that the Cobbler system profiles created as part of the
ubuntu-orchestra-server install actually exist; anecdotal evidence
suggests
that people really don't mess with the distros and profiles available
(they
just set up their systems and go) and so I consider the impact of this
drawback to be extremely limited. Furthermore, we're not actually going
to
get any real arch data out of cobbler *anyway* -- to make this work at
all,
we depend on extracting it from some sort of profile naming convention
--
and so we may as well depend on the convention that already exists.

https://code.launchpad.net/~fwereade/juju/orchestra-series-constraints/+merge/101670

(do not edit description out of merge proposal)

Please review this at https://codereview.appspot.com/6012045/

Affected files:
   A [revision details]
   M juju/providers/orchestra/cobbler.py
   M juju/providers/orchestra/launch.py
   M juju/providers/orchestra/tests/common.py
   M juju/providers/orchestra/tests/data/bootstrap_user_data
   M juju/providers/orchestra/tests/test_bootstrap.py
   M juju/providers/orchestra/tests/test_cobbler.py
   M juju/providers/orchestra/tests/test_launch.py

Revision history for this message
William Reade (fwereade) wrote :
Revision history for this message
William Reade (fwereade) wrote :
Revision history for this message
Kapil Thangavelu (hazmat) wrote :
526. By William Reade

merge parent

Revision history for this message
William Reade (fwereade) wrote :

*** Submitted:

orchestra provider now respects ubuntu-series constraint

This is done by setting a new system profile before powering on the
machine;
and assumes that the Cobbler system profiles created as part of the
ubuntu-orchestra-server install actually exist. Anecdotal evidence
suggests
that people really don't mess with the distros and profiles available
(they
just set up their systems and go) and so I consider the impact of this
drawback to be extremely limited.

Furthermore, while it is possible to extract real arch and series info
from
cobbler (ie we can get a system's arch from its profile's distro, and we
can
partially match new profiles by checking the distro's series and arch)
this
is not enough to select an actual profile without depending on some
convention: we either have to infer the presence of the juju preseed
from
the profile name (as I do currently) or to check the profile itself for
a magic string (ie the path to the juju preseed).

So: we depend on orchestra install conventions, whatever we do; and IMO
it's
cleanest and simplest to actually embrace that and save all the mucking
about with distros and profiles.

R=hazmat
CC=
https://codereview.appspot.com/6012045

https://codereview.appspot.com/6012045/

Preview Diff

Empty

Subscribers

People subscribed via source and target branches

to status/vote changes: