Page Menu
Home
FreeBSD
Search
Configure Global Search
Log In
Files
F168420756
D52451.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Flag For Later
Award Token
Size
1 KB
Referenced Files
None
Subscribers
None
D52451.diff
View Options
diff --git a/release/tools/azure.conf b/release/tools/azure.conf
--- a/release/tools/azure.conf
+++ b/release/tools/azure.conf
@@ -19,20 +19,25 @@
export VM_BOOTPARTSOFFSET=1M
vm_extra_pre_umount() {
- mount -t devfs devfs ${DESTDIR}/dev
-
- # The firstboot_pkgs rc.d script will download the repository
- # catalogue and install or update pkg when the instance first
- # launches, so these files would just be replaced anyway; removing
- # them from the image allows it to boot faster.
- chroot ${DESTDIR} ${EMULATOR} env ASSUME_ALWAYS_YES=yes \
- /usr/sbin/pkg delete -f -y pkg
- rm -r ${DESTDIR}/var/db/pkg/repos/FreeBSD-ports
- rm -r ${DESTDIR}/var/db/pkg/repos/FreeBSD-ports-kmods
-
- chroot ${DESTDIR} ${EMULATOR} pw usermod root -h -
-
- umount ${DESTDIR}/dev
+ # Remove the pkg package and repo databases as they will likely
+ # be out of date by the time the image is used. In unprivileged
+ # builds this is unnecessary as pkg will not be installed to
+ # begin with.
+ if [ -z "${NO_ROOT}" ]; then
+ mount -t devfs devfs ${DESTDIR}/dev
+
+ # The firstboot_pkgs rc.d script will download the repository
+ # catalogue and install or update pkg when the instance first
+ # launches, so these files would just be replaced anyway; removing
+ # them from the image allows it to boot faster.
+ chroot ${DESTDIR} ${EMULATOR} env ASSUME_ALWAYS_YES=yes \
+ /usr/sbin/pkg delete -f -y pkg
+ umount ${DESTDIR}/dev
+ rm -r ${DESTDIR}/var/db/pkg/repos/FreeBSD-ports
+ rm -r ${DESTDIR}/var/db/pkg/repos/FreeBSD-ports-kmods
+ fi
+
+ pw -R ${DESTDIR} usermod root -h -
cat << EOF >> ${DESTDIR}/etc/rc.conf
ifconfig_hn0="SYNCDHCP"
@@ -51,6 +56,7 @@
mlx4en_load="YES"
mlx5en_load="YES"
EOF
+ metalog_add_data ./boot/loader.conf
return 0
}
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Sat, Aug 29, 5:18 AM (18 h, 45 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
37497487
Default Alt Text
D52451.diff (1 KB)
Attached To
Mode
D52451: release: Make azure cloudware images buildable as non-root
Attached
Detach File
Event Timeline
Log In to Comment