.nh .TH buildah-login "1" "Apr 2019" "buildah" .SH NAME .PP buildah-login - Login to a container registry .SH SYNOPSIS .PP \fBbuildah login\fP [\fIoptions\fP] \fIregistry\fP .SH DESCRIPTION .PP \fBbuildah login\fP logs into a specified registry server with the correct username and password. \fBbuildah login\fP reads in the username and password from STDIN. The username and password can also be set using the \fBusername\fP and \fBpassword\fP flags. The path of the authentication file can be specified by the user by setting the \fBauthfile\fP flag. The default path used is \fB${XDG_RUNTIME_DIR}/containers/auth.json\fP\&. If XDG_RUNTIME_DIR is not set, the default is /run/containers/$UID/auth.json. .PP \fBbuildah [GLOBAL OPTIONS]\fP .PP \fBbuildah login [GLOBAL OPTIONS]\fP .PP \fBbuildah login [OPTIONS] REGISTRY [GLOBAL OPTIONS]\fP .SH OPTIONS .PP \fB--authfile\fP .PP Path of the authentication file. Default is ${XDG_\\RUNTIME_DIR}/containers/auth.json. If XDG_RUNTIME_DIR is not set, the default is /run/user/$UID/containers/auth.json. This file is created using \fBbuildah login\fR\&. .PP Note: You can also override the default path of the authentication file by setting the REGISTRY_AUTH_FILE environment variable. \fBexport REGISTRY_AUTH_FILE=path\fR .PP \fB--cert-dir\fP \fIpath\fP .PP Use certificates at \fIpath\fP (*\&.crt, *\&.cert, *\&.key) to connect to the registry. The default certificates directory is \fI/etc/containers/certs.d\fP\&. .PP \fB--compat-auth-file\fP=\fIpath\fP .PP Instead of updating the default credentials file, update the one at \fIpath\fP, and use a Docker-compatible format. .PP \fB--get-login\fP .PP Return the logged-in user for the registry. Return error if no login is found. .PP \fB--help\fP, \fB-h\fP .PP Print usage statement .PP \fB--password\fP, \fB-p\fP .PP Password for registry .PP \fB--password-stdin\fP .PP Take the password from stdin .PP \fB--tls-verify\fP .PP Require HTTPS and verification of certificates when talking to container registries (default: true). If explicitly set to true, then TLS verification will be used. If set to false, then TLS verification will not be used. If not specified, TLS verification will be used unless the target registry is listed as an insecure registry in registries.conf. TLS verification cannot be used when talking to an insecure registry. .PP \fB--username\fP, \fB-u\fP .PP Username for registry .PP \fB--verbose\fP, \fB-v\fP .PP print detailed information about credential store .SH EXAMPLES .EX $ buildah login quay.io Username: qiwanredhat Password: Login Succeeded! .EE .EX $ buildah login -u testuser -p testpassword localhost:5000 Login Succeeded! .EE .EX $ buildah login --authfile ./auth.json quay.io Username: qiwanredhat Password: Login Succeeded! .EE .EX $ buildah login --tls-verify=false -u test -p test localhost:5000 Login Succeeded! .EE .EX $ buildah login --cert-dir /etc/containers/certs.d/ -u foo -p bar localhost:5000 Login Succeeded! .EE .EX $ buildah login -u testuser --password-stdin < pw.txt quay.io Login Succeeded! .EE .EX $ echo $testpassword | buildah login -u testuser --password-stdin quay.io Login Succeeded! .EE .SH SEE ALSO .PP buildah(1), buildah-logout(1)