I am new to kubernetes, how can I make full CI/CD pipeline to create dockers images from jenkins and deploying it to kubernetes cluster running minikube.
I need three containers: 1. frontend: react 2. backend: nodejs 3. mongodb and nginx webserver. I have Jenkins master, Docker and Minikube installed. My App
My docker-compose.yml file:
version: '3'
services:
web:
container_name: frontend
build: ./client
ports:
- "80:80"
links:
- node
volumes:
- ./client/dist:/usr/share/nginx/html"
node:
container_name: server
build: ./server
env_file:
- ./server/.env.example
ports:
- "3001:3001"
links:
- mongo
mongo:
container_name: mongo
image: mongo
ports:
- "27017:27017"
Matt mentioned that this question is too broad and I agree. You did not provide required details and what exactly do you want to achieve.
You can use Jenkins, Docker, Ansible, Helm and Kubernetes stack and it has been explained in this medium article.
For ease of use you can also use Kubernetes Continuous Deploy Plugin In this case you will need to configure a Job and select "Deploy to Kubernetes" and add the kubeconfig (explained in the provided link).
Last but not least just as @t3ng1l mentioned Jenkins X was created for such purposes.