Merge ~andreserl/maas:really_workaround_lp1711760 into maas:master

Proposed by Andres Rodriguez
Status: Merged
Approved by: Andres Rodriguez
Approved revision: 0b9e6b934db7d57988b8ef70d3964ae052f49935
Merge reported by: MAAS Lander
Merged at revision: not available
Proposed branch: ~andreserl/maas:really_workaround_lp1711760
Merge into: maas:master
Diff against target: 25 lines (+2/-2)
2 files modified
src/maasserver/api/machines.py (+1/-1)
src/metadataserver/user_data/templates/base_user_data.sh (+1/-1)
Reviewer Review Type Date Requested Status
Andres Rodriguez (community) Approve
Review via email: mp+332330@code.launchpad.net

Commit message

LP: #1711760 - Fix incorrect comparison that caused to always use the work around.

Drive-by fix to update the API documentation.

To post a comment you must log in.
Revision history for this message
Andres Rodriguez (andreserl) wrote :

selfie!

review: Approve
Revision history for this message
MAAS Lander (maas-lander) wrote :

UNABLE TO START LANDING

STATUS: MISSING COMMIT MESSAGE

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1diff --git a/src/maasserver/api/machines.py b/src/maasserver/api/machines.py
2index 12358af..c382c83 100644
3--- a/src/maasserver/api/machines.py
4+++ b/src/maasserver/api/machines.py
5@@ -560,7 +560,7 @@ class MachineHandler(NodeHandler, OwnerDataMixin, PowerMixin):
6 Some drives implement secure erasure by overwriting themselves so
7 this could still be slow.
8 :type secure_erase: boolean
9- :param quick_erase: Wipe 1MiB at the start and at the end of the drive
10+ :param quick_erase: Wipe 2MiB at the start and at the end of the drive
11 to make data recovery inconvenient and unlikely to happen by
12 accident. This is not secure.
13 :type quick_erase: boolean
14diff --git a/src/metadataserver/user_data/templates/base_user_data.sh b/src/metadataserver/user_data/templates/base_user_data.sh
15index 2a8e911..e9aae3e 100644
16--- a/src/metadataserver/user_data/templates/base_user_data.sh
17+++ b/src/metadataserver/user_data/templates/base_user_data.sh
18@@ -18,7 +18,7 @@ mkdir -p "$BIN_D"
19 # Work around issue where resolv.conf is not set on the ephemeral environment
20 #
21 # First check if a nameserver is set in resolv.conf
22-if ! echo /etc/resolv.conf | grep -qs "nameserver"; then
23+if ! grep -qs nameserver /etc/resolv.conf; then
24 # If it is not, obtain the MAC address of the PXE boot interface
25 mac_address=$(cat /proc/cmdline | grep -o -E '([[:xdigit:]]{1,2}:){5}[[:xdigit:]]{1,2}')
26

Subscribers

People subscribed via source and target branches