Forum Navigation
You need to log in to create posts and topics.

Configuring Kubernetes to use offline registry with secret

Login to your docker registry

Run the following command to login to your offline docker registry

docker login registry.tracston.com

You will be prompted for username and password as you created in your htpasswd.file

Kubernetes secret

A Kubernetes cluster uses the Secret of docker-registry type to authenticate with a container registry to pull a private image.

kubectl create secret docker-registry tracston-secret –docker-server=registry.tracston.com –docker-username=username –docker-password=password  –docker-email=username@tracston.com

If you want to check your installation create a pod file pod.yaml

 

apiVersion: v1

kind: Pod

metadata:

name: ai-tracston-pod

spec:

containers:

– name: ai-tracston

image: ai-tracston:L1.0.2

imagePullSecrets:

– name: tracstonsecret

 

Install check for pod integrity

kubectl apply -f pod.yaml

kubectl get pod ai-tracston-pod