/Infraestructure-buildkite

Demo using dockerfiles, docker-compose, minikube, vault and builkite to push an image to quay.io

Primary LanguageJavaScript

DI Infrastructure

This example includes:

  1. Dockerfile and docker-compose
  2. Minikube
  3. Buildkite to push an image to quay
  4. Add a vault server to secure the process

Docker-compose

To build the nodejs app locally is needed to run the command docker-compose up in the path DITeambuildkite

Minikube

The next steps must be followed:

  1. Start minikube minikube start
  2. Create the deployments kubectl apply [deployment.yml]
  3. Create the services kubectl apply [service.yml]
  4. Run minikube tunnel to expose the service
  5. Run kubectl get all to ensure that the services are running
  6. Go to http://nodejsservice.default.svc.cluster.local:3000/

Run an agent and push to quay

  • To run an agent and vault server is needed go to the path buildkite_agent and run:

docker-compose up that enables the agent and the vault server.

Then make changes in the code, commit and push the pipeline will be running

NOTE: Add a webhook in github, to let the pipeline catch the changes in the repo