Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 26 May 2017 19:02:47 +0000 (UTC)
From:      Glen Barber <gjb@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-10@freebsd.org
Subject:   svn commit: r318963 - in stable: 10/release/tools 11/release/tools
Message-ID:  <201705261902.v4QJ2loW067289@repo.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: gjb
Date: Fri May 26 19:02:46 2017
New Revision: 318963
URL: https://svnweb.freebsd.org/changeset/base/318963

Log:
  MFC r314935 (thompsa):
   Change ec2.conf to use the pkg tool from a chroot rather than trying
   to bootstrap it and fail from the livecd readonly filesystem.
  
  Sponsored by:	The FreeBSD Foundation

Modified:
  stable/10/release/tools/ec2.conf
Directory Properties:
  stable/10/   (props changed)

Changes in other areas also in this revision:
Modified:
  stable/11/release/tools/ec2.conf
Directory Properties:
  stable/11/   (props changed)

Modified: stable/10/release/tools/ec2.conf
==============================================================================
--- stable/10/release/tools/ec2.conf	Fri May 26 17:44:47 2017	(r318962)
+++ stable/10/release/tools/ec2.conf	Fri May 26 19:02:46 2017	(r318963)
@@ -32,7 +32,8 @@ vm_extra_pre_umount() {
 	# 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.
-	env ASSUME_ALWAYS_YES=yes pkg -c ${DESTDIR} delete -f -y pkg
+	chroot ${DESTDIR} env ASSUME_ALWAYS_YES=yes \
+		/usr/sbin/pkg delete -f -y pkg
 	rm ${DESTDIR}/var/db/pkg/repo-*.sqlite
 
 	# The size of the EC2 root disk can be configured at instance launch



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201705261902.v4QJ2loW067289>