mirror of
https://git.launchpad.net/livecd-rootfs
synced 2025-08-14 18:24:15 +00:00
Imported 2.818
No reason for CPC update specified.
This commit is contained in:
parent
e60564a4f7
commit
3eaf5fa5e0
16
debian/changelog
vendored
16
debian/changelog
vendored
@ -1,3 +1,19 @@
|
||||
livecd-rootfs (2.818) lunar; urgency=medium
|
||||
|
||||
[ Dave Jones ]
|
||||
* raspi: drop mkswap.service and swapfile.swap units in
|
||||
099-ubuntu-image-customization.chroot in favour of units provided by
|
||||
ubuntu-raspi-settings-desktop
|
||||
* raspi: drop 01-network-manager-all.yaml in favour of configuration
|
||||
provided by ubuntu-raspi-settings-desktop
|
||||
* raspi: drop growfs option from fstab in favour of growroot-almost
|
||||
service provided by ubuntu-raspi-settings-desktop
|
||||
|
||||
[ William 'jawn-smith' Wilson ]
|
||||
* Skip oem-config setup in hooks if the oem user already exists.
|
||||
|
||||
-- Dave Jones <dave.jones@canonical.com> Tue, 28 Mar 2023 14:38:55 +0100
|
||||
|
||||
livecd-rootfs (2.817) lunar; urgency=medium
|
||||
|
||||
[ John Chittum ]
|
||||
|
@ -999,7 +999,7 @@ configure_network_manager() {
|
||||
# default. Installing NM on an existing system only manages wifi and wwan via
|
||||
# /usr/lib/NetworkManager/conf.d/10-globally-managed-devices.conf. When setting
|
||||
# the global backend to NM, netplan overrides that file.
|
||||
if [ -e chroot/usr/sbin/NetworkManager -a ! -f chroot/etc/netplan/01-network-manager-all.yaml ]; then
|
||||
if [ -e chroot/usr/sbin/NetworkManager -a ! -f chroot/etc/netplan/01-network-manager-all.yaml -a "$SUBPROJECT" != "desktop-preinstalled" ]; then
|
||||
echo "===== Enabling all devices in NetworkManager ===="
|
||||
mkdir -p chroot/etc/netplan
|
||||
cat <<EOF > chroot/etc/netplan/01-network-manager-all.yaml
|
||||
|
@ -11,18 +11,22 @@ if [ "$IMAGEFORMAT" == "none" ]; then
|
||||
touch /var/log/syslog
|
||||
chown syslog:adm /var/log/syslog
|
||||
|
||||
# Create the oem user account
|
||||
# Create the oem user account only if it doesn't already exist
|
||||
if ! id "oem" &>/dev/null; then
|
||||
/usr/sbin/useradd -d /home/oem -G adm,sudo -m -N -u 29999 oem
|
||||
/usr/sbin/oem-config-prepare --quiet
|
||||
touch "/var/lib/oem-config/run"
|
||||
fi
|
||||
|
||||
/usr/sbin/useradd -d /home/oem -G adm,sudo -m -N -u 29999 oem
|
||||
|
||||
/usr/sbin/oem-config-prepare --quiet
|
||||
touch "/var/lib/oem-config/run"
|
||||
|
||||
# Update the fstab to include the "discard" option, and
|
||||
# "x-systemd.growfs" to ensure the root partition is expanded on first
|
||||
# boot
|
||||
# Update the fstab to include the "discard" option
|
||||
awk \
|
||||
-v root_fs_label="writable" \
|
||||
-v root_fs_options="discard,x-systemd.growfs" \
|
||||
-v root_fs_options="discard" \
|
||||
'
|
||||
BEGIN { OFS="\t"; count=0; }
|
||||
|
||||
@ -51,35 +55,5 @@ if [ "$IMAGEFORMAT" == "none" ]; then
|
||||
}
|
||||
' /etc/fstab > /etc/fstab.new
|
||||
mv /etc/fstab.new /etc/fstab
|
||||
|
||||
# Add units for a 1GiB swapfile, generated on first boot
|
||||
cat << EOF > /lib/systemd/system/mkswap.service
|
||||
[Unit]
|
||||
Description=Create the default swapfile
|
||||
DefaultDependencies=no
|
||||
Requires=local-fs.target
|
||||
After=local-fs.target
|
||||
Before=swapfile.swap
|
||||
ConditionPathExists=!/swapfile
|
||||
|
||||
[Service]
|
||||
Type=oneshot
|
||||
ExecStartPre=fallocate -l 1GiB /swapfile
|
||||
ExecStartPre=chmod 600 /swapfile
|
||||
ExecStart=mkswap /swapfile
|
||||
|
||||
[Install]
|
||||
WantedBy=swap.target
|
||||
EOF
|
||||
cat << EOF > /lib/systemd/system/swapfile.swap
|
||||
[Unit]
|
||||
Description=The default swapfile
|
||||
|
||||
[Swap]
|
||||
What=/swapfile
|
||||
EOF
|
||||
mkdir -p /lib/systemd/system/swap.target.wants
|
||||
ln -s ../mkswap.service /lib/systemd/system/swap.target.wants/
|
||||
ln -s ../swapfile.swap /lib/systemd/system/swap.target.wants/
|
||||
fi
|
||||
fi
|
||||
|
Loading…
x
Reference in New Issue
Block a user