ingress-nginx-helm/docs/examples/docker-registry
Gerald Pape 017e1ecde3
Fix Ingress resources in docs (#7579)
* fix Ingress resources in docs

Signed-off-by: Gerald Pape <gerald@giantswarm.io>

* move to ingressClassName

* fix more Ingress resource examples

* empty commit

Signed-off-by: Gerald Pape <gerald@giantswarm.io>

* make NOTES.txt aware of version + add notice about ingress version to examples main page

* add link to legacy documentation

Signed-off-by: Gerald Pape <gerald@giantswarm.io>
2021-11-09 07:43:49 -08:00
..
deployment.yaml Migrate ingress definitions from extensions to networking.k8s.io 2019-12-12 21:25:00 -03:00
ingress-with-tls.yaml Fix Ingress resources in docs (#7579) 2021-11-09 07:43:49 -08:00
ingress-without-tls.yaml Fix Ingress resources in docs (#7579) 2021-11-09 07:43:49 -08:00
README.md Change all master reference to main (#7369) 2021-08-06 17:07:29 -07:00

Docker registry

This example demonstrates how to deploy a docker registry in the cluster and configure Ingress enable access from Internet

Deployment

First we deploy the docker registry in the cluster:

kubectl apply -f https://raw.githubusercontent.com/kubernetes/ingress-nginx/main/docs/examples/docker-registry/deployment.yaml

!!! Important DO NOT RUN THIS IN PRODUCTION

This deployment uses `emptyDir` in the `volumeMount` which means the contents of the registry will be deleted when the pod dies.

The next required step is creation of the ingress rules. To do this we have two options: with and without TLS

Without TLS

Download and edit the yaml deployment replacing registry.<your domain> with a valid DNS name pointing to the ingress controller:

wget https://raw.githubusercontent.com/kubernetes/ingress-nginx/main/docs/examples/docker-registry/ingress-without-tls.yaml

!!! Important Running a docker registry without TLS requires we configure our local docker daemon with the insecure registry flag.

Please check deploy a plain http registry

With TLS

Download and edit the yaml deployment replacing registry.<your domain> with a valid DNS name pointing to the ingress controller:

wget https://raw.githubusercontent.com/kubernetes/ingress-nginx/main/docs/examples/docker-registry/ingress-with-tls.yaml

Deploy kube lego use Let's Encrypt certificates or edit the ingress rule to use a secret with an existing SSL certificate.

Testing

To test the registry is working correctly we download a known image from docker hub, create a tag pointing to the new registry and upload the image:

docker pull ubuntu:16.04
docker tag ubuntu:16.04 `registry.<your domain>/ubuntu:16.04`
docker push `registry.<your domain>/ubuntu:16.04`

Please replace registry.<your domain> with your domain.