diff options
author | Colin Percival <cperciva@FreeBSD.org> | 2020-09-13 19:56:53 +0000 |
---|---|---|
committer | Colin Percival <cperciva@FreeBSD.org> | 2020-09-13 19:56:53 +0000 |
commit | a72eeb2025fc052c71771624b1d7ac51639103d4 (patch) | |
tree | e0f7b5a80b5b2c9f0ce47804a595b041b6ed2551 /release/tools | |
parent | ff5188db54f94dd48dcd1a029fbbcfef42e9992b (diff) | |
download | src-test2-a72eeb2025fc052c71771624b1d7ac51639103d4.tar.gz src-test2-a72eeb2025fc052c71771624b1d7ac51639103d4.zip |
Notes
Diffstat (limited to 'release/tools')
-rw-r--r-- | release/tools/ec2.conf | 16 |
1 files changed, 13 insertions, 3 deletions
diff --git a/release/tools/ec2.conf b/release/tools/ec2.conf index aac87e93e28b..e726ccadc048 100644 --- a/release/tools/ec2.conf +++ b/release/tools/ec2.conf @@ -6,7 +6,7 @@ # Packages to install into the image we're creating. This is a deliberately # minimalist set, providing only the packages necessary to bootstrap further # package installation as specified via EC2 user-data. -export VM_EXTRA_PACKAGES="ec2-scripts firstboot-freebsd-update firstboot-pkgs dual-dhclient-daemon ebsnvme-id" +export VM_EXTRA_PACKAGES="ec2-scripts firstboot-freebsd-update firstboot-pkgs isc-dhcp44-client ebsnvme-id" # Include the amazon-ssm-agent package in amd64 images, since some users want # to be able to use it on systems which are not connected to the Internet. @@ -63,9 +63,19 @@ vm_extra_pre_umount() { # via EC2 user-data. echo 'firstboot_pkgs_list="awscli"' >> ${DESTDIR}/etc/rc.conf - # Enable IPv6 on all interfaces, and use DHCP on both IPv4 and IPv6. + # Enable IPv6 on all interfaces, and spawn DHCPv6 via rtsold echo 'ipv6_activate_all_interfaces="YES"' >> ${DESTDIR}/etc/rc.conf - echo 'dhclient_program="/usr/local/sbin/dual-dhclient"' >> ${DESTDIR}/etc/rc.conf + echo 'rtsold_enable="YES"' >> ${DESTDIR}/etc/rc.conf + echo 'rtsold_flags="-M /usr/local/libexec/rtsold-M -a"' >> ${DESTDIR}/etc/rc.conf + + # Provide a script which rtsold can use to launch DHCPv6 + mkdir -p ${DESTDIR}/usr/local/libexec + cat > ${DESTDIR}/usr/local/libexec/rtsold-M <<'EOF' +#!/bin/sh + +/usr/local/sbin/dhclient -6 -nw -N -cf /dev/null $1 +EOF + chmod 755 ${DESTDIR}/usr/local/libexec/rtsold-M # The EC2 console is output-only, so while printing a backtrace can # be useful, there's no point dropping into a debugger or waiting |