Drop NetworkManager default config (#1813)

* Drop default NetworkManager configuration

NetworkManager will automatically connect using the global defaults.
Also Supervisor today will create a profiles once the user configures
the network explicitly.

* Create system-connection directory
This commit is contained in:
Stefan Agner 2022-03-25 08:53:30 +01:00 committed by GitHub
parent 59d69209dc
commit 99be958c4f
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 1 additions and 21 deletions

View File

@ -1,13 +0,0 @@
[connection]
id=Home Assistant OS default
uuid=f62bf7c2-e565-49ff-bbfc-a4cf791e6add
type=802-3-ethernet
llmnr=2
mdns=2
[ipv4]
method=auto
[ipv6]
addr-gen-mode=stable-privacy
method=auto

View File

@ -3,11 +3,7 @@
mkdir -p /mnt/overlay/etc/
# Network
if [ ! -d /mnt/overlay/etc/NetworkManager/system-connections ]; then
mkdir -p /mnt/overlay/etc/NetworkManager/system-connections
cp -fp /etc/NetworkManager/system-connections/* /mnt/overlay/etc/NetworkManager/system-connections/
chmod 600 /mnt/overlay/etc/NetworkManager/system-connections/*
fi
mkdir -p /mnt/overlay/etc/NetworkManager/system-connections
if [ ! -f /mnt/overlay/etc/hostname ]; then
cp -fp /etc/hostname /mnt/overlay/etc/hostname

View File

@ -19,9 +19,6 @@ function fix_rootfs() {
# systemd-update-done.service relies on writeable /var and /etc
rm -f "${TARGET_DIR}/usr/lib/systemd/system/sysinit.target.wants/systemd-update-done.service"
# Fix: permission for system connection files
chmod 600 "${TARGET_DIR}/etc/NetworkManager/system-connections"/*
# Fix: tempfs with /srv
sed -i "/srv/d" "${TARGET_DIR}/usr/lib/tmpfiles.d/home.conf"