manage login-private-registry

Log in to your private container registry before mirroring images to it.

Extended description

The login-private-registry command is a prerequisite to the mirror-images command. You must log in to your private container registry before you can mirror images to it.

Best practice: Use a private container registry that is secured with credentials.

Syntax

cpd-cli manage login-private-registry \
PRIVATE_REGISTRY_LOCATION \
[PRIVATE_REGISTRY_PUSH_USER] \
[PRIVATE_REGISTRY_PUSH_PASSWORD]

Arguments

Argument Description
PRIVATE_REGISTRY_LOCATION The host name or IP address of the private container registry.
Keep the following guidance in mind:
  • Do not specify http:// or https://.
  • If the registry is running on port 80 or 443 you can omit the port. However, if the registry is running on a different port, you must specify the port.
PRIVATE_REGISTRY_PUSH_USER The username of a user who has the required privileges to push images to the private container registry.

If the registry is not secured with a username and password, omit this argument.

PRIVATE_REGISTRY_PUSH_PASSWORD The password or key of the user who has the required privileges to push images to the private container registry.

If the registry is not secured with a username and password, omit this argument.

Options

The login-private-registry command has no options.

Examples

Best practice: The following example uses the recommended installation environment variables.

Use a script to create environment variables with the correct values for your environment. For details, see Best practice: Setting up install variables.

Log in to your private container registry
cpd-cli manage login-private-registry \
${PRIVATE_REGISTRY_LOCATION} \
${PRIVATE_REGISTRY_PUSH_USER} \
${PRIVATE_REGISTRY_PUSH_PASSWORD}