17653 zone install fails with pkg.oracle.com/solaris/support set
authorTim Foster <tim.s.foster@oracle.com>
Thu, 06 Jan 2011 09:08:45 +1300
changeset 2179 d5e39d973fdd
parent 2178 7c123147a909
child 2180 50a104a28193
17653 zone install fails with pkg.oracle.com/solaris/support set 17683 pkgcreatezone does a chown/chmod on the wrong path
src/brand/pkgcreatezone
src/client.py
--- a/src/brand/pkgcreatezone	Wed Jan 05 11:45:09 2011 -0800
+++ b/src/brand/pkgcreatezone	Thu Jan 06 09:08:45 2011 +1300
@@ -343,8 +343,8 @@
 	printf "$m_cert_prop\n" $(basename $certfile)
 	mkdir -p -m 755 $ZONEROOT/$KEYDIR || fail_fatal "$f_cert_prop"
 	cp $certfile $ZONEROOT/$newcertlocation || fail_fatal "$f_cert_prop"
-	chmod 644 $ZONEROOT/$newkeylocation
-	chown -h root:root $ZONEROOT/$newkeylocation
+	chmod 644 $ZONEROOT/$newcertlocation
+	chown -h root:root $ZONEROOT/$newcertlocation
 fi
 
 #
--- a/src/client.py	Wed Jan 05 11:45:09 2011 -0800
+++ b/src/client.py	Thu Jan 06 09:08:45 2011 +1300
@@ -21,7 +21,7 @@
 #
 
 #
-# Copyright (c) 2007, 2010, Oracle and/or its affiliates. All rights reserved.
+# Copyright (c) 2007, 2011, Oracle and/or its affiliates. All rights reserved.
 #
 
 #
@@ -3890,10 +3890,11 @@
                 progtrack = get_tracker()
                 api_inst = api.image_create(PKG_CLIENT_NAME, CLIENT_API_VERSION,
                     image_dir, imgtype, is_zone, facets=facets, force=force,
-                    mirrors=add_mirrors, origins=add_origins, prefix=pub_name,
-                    progtrack=progtrack, refresh_allowed=refresh_allowed,
-                    ssl_cert=ssl_cert, ssl_key=ssl_key, repo_uri=repo_uri,
-                    variants=variants, props=set_props)
+                    mirrors=list(add_mirrors), origins=list(add_origins),
+                    prefix=pub_name, progtrack=progtrack,
+                    refresh_allowed=refresh_allowed, ssl_cert=ssl_cert,
+                    ssl_key=ssl_key, repo_uri=repo_uri, variants=variants,
+                    props=set_props)
                 img = api_inst.img
         except api_errors.InvalidDepotResponseException, e:
                 # Ensure messages are displayed after the spinner.