ezgh registry login [--expires-in-days n] [--api-key-stdin] [flags]Sign docker in to the project’s registry host with an API key, which is what the registry takes as the password. Runs docker login <host> --username ezgh --password-stdin; the key is never shown.
The key is this profile’s own when it uses one (EZGH_API_KEY, an API key from ezgh auth set-api-key, or an instance’s or pod’s Bot key). With a login from ezgh login, which the registry doesn’t take, it creates an API key for you named after the host, expiring after 30 days (--expires-in-days to change it): docker is refused once it expires, so run this again then. Each run creates a new key, and earlier ones keep working until they expire or you revoke them with ezgh iam api-keys delete. --api-key-stdin signs in with a key read from standard input instead, such as a bot’s, to limit what docker can push and pull.
For podman, crane or another client, use ezgh registry get-login-password.
Part of ezgh registry.
Examples
ezgh registry login
ezgh registry login --expires-in-days 7
ezgh iam api-keys create ci-push --bot ci --expires-in-days 90 | ezgh registry login --api-key-stdinFlags
| Flag | Type | Default | Description |
|---|---|---|---|
--api-key-stdin |
boolean | sign in with an API key read from standard input | |
--expires-in-days |
int | 30 |
with a login from ezgh login: expire the key it creates after 1 to 365 days |
This command also takes the global flags.