Pull Secrets
DevSpace allows you to configure additional pull secrets that should be created in the target namespace. For each configured pull secret in the devspace.yaml, DevSpace will create a secret in the target namespace and add the secret to the imagePullSecrets field of the service account.
For images, DevSpace will also automatically create a pull secret, if authentication data can be found in the local docker store and creation is enabled via createPullSecret.
Image Pull Secrets are defined in the pullSecrets section of the devspace.yaml.
- With Password
- From Docker
- Custom Secret & Service Account
# If you don't want to specify the password and username directly in the config
# you can use variables, .env file or save the credentials in the local docker store
pullSecrets:
my-pullsecret:
registry: my-registry.com:5000
username: ${REGISTRY_USER}
password: ${REGISTRY_PASSWORD}
# If you leave out the username & password DevSpace will try
# to get these from the local docker store. Make sure you
# are logged into the registry with `docker login my-registry.com:5000`
pullSecrets:
my-pullsecret:
registry: my-registry.com:5000
pullSecrets:
my-pullsecret:
registry: my-registry.com:5000
secret: my-pull-secret-name
serviceAccounts:
- default
- my-other-service-account
Configuration
pullSecrets required <pullSecret_name>:object
PullSecrets are image pull secrets that will be created by devspace in the target namespace
during devspace dev or devspace deploy. DevSpace will merge all defined pull secrets into a single
one or the one specified.
pullSecrets required <pullSecret_name>:object <pullSecret_name> required string
Name is the pull secret name to deploy
<pullSecret_name> required string registry required string
The registry to create the image pull secret for.
Empty string == docker hub
e.g. gcr.io
registry required string username required string
The username of the registry. If this is empty, devspace will try
to receive the auth data from the local docker
username required string password required string
The password to use for the registry. If this is empty, devspace will
try to receive the auth data from the local docker
password required string email required string
The optional email to use
email required string secret required string
The secret to create
secret required string serviceAccounts required string[]
The service account to add the secret to
serviceAccounts required string[]