Merge lp:~blake-rouse/maas/fix-bug-1303915 into lp:maas/trunk

Proposed by Blake Rouse on 2014-04-07
Status: Merged
Approved by: Blake Rouse on 2014-04-07
Approved revision: 2238
Merged at revision: 2239
Proposed branch: lp:~blake-rouse/maas/fix-bug-1303915
Merge into: lp:maas/trunk
Diff against target: 12 lines (+2/-2)
1 file modified
src/provisioningserver/custom_hardware/seamicro.py (+2/-2)
To merge this branch: bzr merge lp:~blake-rouse/maas/fix-bug-1303915
Reviewer Review Type Date Requested Status
Julian Edwards (community) Needs Fixing on 2014-04-08
Andres Rodriguez (community) 2014-04-07 Approve on 2014-04-07
Review via email: mp+214588@code.launchpad.net

Commit message

Force SM15k nodes to boot using PXE when booting with RESTAPI v2, and to force powering off.

Description of the change

Now when powering on SM15k nodes with the REST API v2 the nodes are forced to boot with PXE. This ignores the BIOS settings for the node, making sure that the node uses MAAS to boot.

To post a comment you must log in.
Andres Rodriguez (andreserl) wrote :

lgtm! I'm sure this has been tested in real hardware and works just fine.

review: Approve
Julian Edwards (julian-edwards) wrote :

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

 review: needs-fixing

On 08/04/14 07:39, Andres Rodriguez wrote:
> Review: Approve
>
> lgtm! I'm sure this has been tested in real hardware and works just
> fine.
>

Sadly, it still needs unit tests in here...
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1
Comment: Using GnuPG with Thunderbird - http://www.enigmail.net/

iEYEARECAAYFAlNDmMgACgkQWhGlTF8G/Hcf9ACfdeh9cfyR74BU6d1LObKRTM5e
Y1AAoIjZ+GYzf41IosaEclc5uLfR8XcP
=nLaF
-----END PGP SIGNATURE-----

review: Needs Fixing

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'src/provisioningserver/custom_hardware/seamicro.py'
2--- src/provisioningserver/custom_hardware/seamicro.py 2014-04-07 10:39:19 +0000
3+++ src/provisioningserver/custom_hardware/seamicro.py 2014-04-07 17:31:43 +0000
4@@ -317,6 +317,6 @@
5 if api:
6 server = api.servers.get(server_id)
7 if power_change == "on":
8- server.power_on()
9+ server.power_on(using_pxe=True)
10 elif power_change == "off":
11- server.power_off()
12+ server.power_off(force=True)