Session by Divyansh Khandelwal
This repository contains the code used in the session with some useful links for the community members.
Here is the git repo
Do drop a star, will make me happy 😊
Clone the Repository
git clone https://github.com/noob-master147/codebar-devops.git
Skip this step if you already have installed docker and docker compose.
Docker Compose Guide
Confirm your installation by running sudo docker version
Step 3 -> Create account on Docker Hub
sudo docker-compose up --build -d
Check the services
sudo docker ps
Port | Service |
---|---|
http://localhost:3000 | React-Frontend |
localhost:27017 | MongoDB |
Use the script available here
Drop a ⭐ on the gist or bookmark it.
-
sudo curl https://gist.githubusercontent.com/noob-master147/f96aef074bf28d1db7276e365b646ba5/raw/692550e5c5d053fff0b876fcfd66eac25c073f9d/script.sh >> script.sh
-
sudo bash script.sh
- After this step you will have docker and docker-compose installed in your EC2 instance.
- After this step you will have docker and docker-compose installed in your EC2 instance.
sudo nano docker-compose.yml
- paste the docker-compose file contents.
- press
ctrl+x y enter
to save and exit.
sudo docker-compose pull
sudo docker-compose up --build
- add repository secrets
- HOST
- PORT
- USERNAME
- KEY
- DOCKER_USER
- DOCKER_PASSWORD
- Create Workflow YAML file
- use this gist as template.
- update the tags and the image names