This is a simple Node.js web application built using Express.js.
It demonstrates how to automate the process of building and deploying Docker containers using GitHub Actions CI/CD pipeline.
- Node.js with Express
- Docker for containerization
- GitHub Actions for CI/CD automation
- DockerHub to host built images
-
Created a simple Express.js server
-
Wrote a
Dockerfileto containerize the app -
Set up
.github/workflows/main.ymlfor CI/CD pipeline -
Stored DockerHub credentials in GitHub Secrets
-
Changed the branch name into master into main
-
On every push to the
masterbranch: -
GitHub Actions builds the Docker image
-
Tags it with the branch name
DOCKER_USERNAME– Your DockerHub usernameDOCKER_PASSWORD– Your DockerHub password or access token
You can pull the image from DockerHub and run it:
Pull the Docker image and run the container:
docker pull srilakshmiyannam/nodejs-demo-app:master
docker run -p 3000:3000 srilakshmiyannam/nodejs-demo-app:master


