In this example, the SolarisStudio repository exists in addition to the Solaris repository. The Solaris repository is accessible from http://localhost/ using port 81, as specified in the solaris instance of the pkg/server service. See Enabling Users to Retrieve Packages Using an HTTP Interface.
Use the add subcommand of the svccfg command to add a new instance of the pkg/server service.
$ svccfg -s pkg/server add studio
$ svcs pkg/server STATE STIME FMRI online 14:54:16 svc:/application/pkg/server:default online 14:54:20 svc:/application/pkg/server:studio online 14:54:20 svc:/application/pkg/server:solaris
Set the path where this instance of the service can find the repository data.
$ svccfg -s pkg/server:studio setprop pkg/inst_root=/export/IPSpkgrepos/SolarisStudio
$ svccfg -s pkg/server:studio setprop pkg/port=82
See Configuring a Simple Prefixed Proxy for an example of setting the pkg/proxy_base.
Make sure the repository name and description are set as shown in Modifying Repository Property Values.
Restart the package depot server service.
$ svcadm refresh pkg/server:studio $ svcadm enable pkg/server:studio
Open a browser window on the http://localhost:82/ location.
If you did not set the port number, the default is 80. View your repository at http://localhost:80/ or http://localhost/.
If the port number is also being used by another pkg/server instance, append the publisher name to the location to see the new packages. For example, view your repository at http://localhost:81/solarisstudio/.
Set the publisher origin to one of the following values:
The pkg/inst_root location.
$ pkg set-publisher -G '*' -M '*' -g /export/IPSpkgrepos/SolarisStudio/ \ solarisstudio
The pkg/port location.
$ pkg set-publisher -G '*' -M '*' -g http://localhost:82/ solarisstudio
See also
See Multiple Repositories Under One Domain for information about running multiple repositories under one domain name with different prefixes such as http://pkg.example.com/solaris and http://pkg.example.com/studio.