This directory contains a sample ASP.NET Core application that acts as a "backend service" within a cluster as well as the definition for the Kubernetes manifests for the ingress controller.
From the base directory for this repo (where the .sln file is), run the commands:
docker build -t backend:latest -f ./samples/KubernetesIngress.Sample/backend/Dockerfile .
- Open the backend.yaml file
- Modify the container image to match the name used when building the image, e.g. change
<REGISTRY_NAME>/backend:<TAG>tobackend:latest - Run the command
kubectl apply -f ./samples/KubernetesIngress.Sample/backend/backend.yaml - Run the command
kubectl apply -f ./samples/KubernetesIngress.Sample/backend/ingress-sample.yaml
To undeploy the backend, run the commands
kubectl delete -f ./samples/KubernetesIngress.Sample/backend/ingress-sample.yaml
kubectl delete -f ./samples/KubernetesIngress.Sample/backend/backend.yaml