Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
Exercise:
Your goal is to make use all that you have learned so far in the course, take a containerized application, do minimal tweaking and make it available in production. The bottle application is a simple python application that makes use of the bottle web framework. The ready container is available at the Dockerhub.
Deployment:
To create a working deployment of yiorgos/bottle, you need to know the following things:
- The container listens on port 8080
- The container expects to connect to a MongoDB. For this reason you need to set an environment variable named
MONGODB_HOST
with a value ofmongo-mongodb.default.svc.cluster.local
. - The container handles web requests to /healthz differently. Consequently, you are expected to write a Liveness test that makes use of this endpoint.
- (Optional) The container expects to mount a specific python file at
/usr/src/names_generator.py
. It expects to find it from a configMap that you will create in your namespace - The deployment should spin more than one containers
Service:
Once you have the deployment up and running, create a service that links with the deployment's pods.
Ingress:
Once your service is set, create an Ingress object so that this application is available to users outside the Kubernetes cluster.
Do not panic and always ask questions.
Add Comment
Please, Sign In to add comment