Configuring Proxies to the Package Repository for Non-Global Zones

You have two options when connecting to the package repository from a zone. You can create persistent proxies, or specify the proxies during package install.

Access to repositories configured in the global zone is provided to non-global zones using the system-repository service. Any updates to proxies for origins in the global zone are automatically made to the system-repository configuration. Using this method, no modifications are required to the system-repository SMF service, as the following example illustrates.

Example 6-1 Configuring the Proxy in the Global Zone

$ pfexec pkg set-publisher --proxy http://www-proxy -g http://pkg-server pub

No port specification is required unless the proxy accepts connections on a port other than 80. If zones are on the system, the system-repository service is restarted, and the proxy is used to provide access to pkg-server.