Merge ~bjornt/maas:bug-1888536-2.8 into maas:2.8

Proposed by Björn Tillenius
Status: Merged
Approved by: Björn Tillenius
Approved revision: 7f34bda38bfe657fc8f837f0361de424883bbbfe
Merge reported by: MAAS Lander
Merged at revision: not available
Proposed branch: ~bjornt/maas:bug-1888536-2.8
Merge into: maas:2.8
Diff against target: 13 lines (+2/-1)
1 file modified
snap/local/tree/bin/run-named (+2/-1)
Reviewer Review Type Date Requested Status
MAAS Lander Approve
Björn Tillenius Approve
Review via email: mp+388567@code.launchpad.net

Commit message

LP: #1888536 - named.conf.options.inside.maas reverts to default

run-named always generated a blank config for bind when it's started.

It's questionable why we need to do that on every start, but for now, we
don't generate a config if a config is alrady there.

This should be safe enough to backport, and then we can revisit this
later, to see if we can fix it in a better way.

(cherry picked from commit 192fd8b70d0524683a50f0510577bdb1dc89ec5a)

To post a comment you must log in.
Revision history for this message
Björn Tillenius (bjornt) wrote :

Self-approve backport

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

UNIT TESTS
-b bug-1888536-2.8 lp:~bjornt/maas/+git/maas into -b 2.8 lp:~maas-committers/maas

STATUS: SUCCESS
COMMIT: 7f34bda38bfe657fc8f837f0361de424883bbbfe

review: Approve

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1diff --git a/snap/local/tree/bin/run-named b/snap/local/tree/bin/run-named
2index bd0c252..13c167c 100755
3--- a/snap/local/tree/bin/run-named
4+++ b/snap/local/tree/bin/run-named
5@@ -12,6 +12,7 @@ cp -f "$SNAP/usr/share/maas/bind/named.conf" "$SNAP_DATA/bind/"
6 mkdir -p "$SNAP_DATA/bind/cache"
7
8 # generate MAAS bind configuration
9-MAAS_DNS_CONFIG_DIR="$SNAP_DATA/bind" "$SNAP/bin/maas-rack" setup-dns
10+MAAS_DNS_CONFIG_DIR="$SNAP_DATA/bind" "$SNAP/bin/maas-rack" \
11+ setup-dns --no-clobber
12
13 exec "$SNAP/usr/sbin/named" -c "$SNAP_DATA/bind/named.conf" -g

Subscribers

People subscribed via source and target branches