2014-10-14 11:48:28 +00:00
|
|
|
#!/bin/sh
|
|
|
|
#
|
|
|
|
# $FreeBSD$
|
|
|
|
#
|
|
|
|
|
|
|
|
# Set to a list of packages to install.
|
|
|
|
# Example:
|
2014-11-21 02:30:37 +00:00
|
|
|
#export VM_EXTRA_PACKAGES="www/apache24"
|
2015-01-16 15:37:07 +00:00
|
|
|
export VM_EXTRA_PACKAGES="sysutils/azure-agent"
|
2014-10-14 11:48:28 +00:00
|
|
|
|
|
|
|
# Set to a list of third-party software to enable in rc.conf(5).
|
|
|
|
# Example:
|
|
|
|
#export VM_RC_LIST="apache24"
|
2014-10-14 12:04:50 +00:00
|
|
|
export VM_RC_LIST=
|
2014-11-05 13:22:19 +00:00
|
|
|
|
|
|
|
vm_extra_pre_umount() {
|
Chase r284656 and r284658:
Remove the Azure-local vm_extra_create_disk(), since we no longer
need qemu-img to convert the final VHD image to an Azure-compatible
format.
Although the waagent utility is installed from ports, create the
symlink to /usr/sbin, pending investigation on where this is
hard-coded, so it can be reported upstream. In the meantime, this
is good enough.
MFC after: 3 days
X-MFC-Needs: r284269, r284270, r284271, r284655,
r284656, r284657, r284658, r284659
X-MFC-Note: Required for 10.2-RELEASE, marcel@ has
implicit approval for the required changes
Sponsored by: The FreeBSD Foundation
2015-06-21 04:34:57 +00:00
|
|
|
chroot ${DESTDIR} ln -s /usr/local/sbin/waagent /usr/sbin/waagent
|
2015-06-19 23:03:05 +00:00
|
|
|
chroot ${DESTDIR} /usr/local/sbin/waagent -verbose -install
|
|
|
|
yes | chroot ${DESTDIR} /usr/local/sbin/waagent -deprovision
|
2014-11-05 13:22:19 +00:00
|
|
|
echo 'sshd_enable="YES"' >> ${DESTDIR}/etc/rc.conf
|
|
|
|
echo 'ifconfig_hn0="SYNCDHCP"' >> ${DESTDIR}/etc/rc.conf
|
|
|
|
echo 'waagent_enable="YES"' >> ${DESTDIR}/etc/rc.conf
|
|
|
|
echo 'console="comconsole vidconsole"' >> ${DESTDIR}/boot/loader.conf
|
|
|
|
echo 'comconsole_speed="115200"' >> ${DESTDIR}/boot/loader.conf
|
|
|
|
|
2014-11-21 02:30:37 +00:00
|
|
|
rm -f ${DESTDIR}/etc/resolv.conf
|
|
|
|
|
2014-11-05 13:22:19 +00:00
|
|
|
return 0
|
|
|
|
}
|