From f50579f39da3b3d2d2811b368e55a39ae54df0d6 Mon Sep 17 00:00:00 2001 From: cperciva Date: Tue, 26 Feb 2019 05:37:49 +0000 Subject: [PATCH] MFC r344315: Fix sed script to insert Amazon NTP server into ntp.conf once rather than twice. Reminded by: rgrimes --- release/tools/ec2.conf | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/release/tools/ec2.conf b/release/tools/ec2.conf index c08b32e6757..7e1f2051a01 100644 --- a/release/tools/ec2.conf +++ b/release/tools/ec2.conf @@ -83,7 +83,7 @@ vm_extra_pre_umount() { # Use the NTP service provided by Amazon sed -i '' -e 's/^pool/#pool/' \ - -e 's/^#server.*/server 169.254.169.123 iburst/' \ + -e '1,/^#server/s/^#server.*/server 169.254.169.123 iburst/' \ ${DESTDIR}/etc/ntp.conf # The first time the AMI boots, the installed "first boot" scripts -- 2.45.0