As a fresher starting my DevOps journey, I wanted to get hands-on experience by building a complete project that covered deployment, automation, and observability. Recently, I worked on a Flask-based backend with a frontend, and deployed it using Docker, GitHub Actions (CI/CD), Prometheus, and Grafana on AWS EC2.
This project gave me a clear view of how real-world DevOps workflows are built and managed. Here’s my journey:
- Setting Up the Environment
Launched an AWS EC2 Ubuntu instance.
Configured security groups to allow ports (22, 80, 8080, 8000, 9090, etc.).
Installed Docker and Git for containerization and version control.
- Dockerizing the Applications
Created Dockerfiles for both Flask backend and frontend.
Defined services in a docker-compose.yml file.
Exposed backend on port 8000 and frontend on 8080.
Tested containers locally using docker ps and checked application through public IP.
- CI/CD Pipeline with GitHub Actions
Added a GitHub Actions workflow to build and push Docker images on every commit.
Ensured automation of testing and container build.
Verified pipeline runs through GitHub Actions dashboard.
- Monitoring with Prometheus & Grafana
Configured Prometheus to scrape backend metrics.
Setup Grafana dashboards to visualize application health.
Verified metrics like uptime and API response using dashboards.
- Handling Challenges
Initially frontend didn’t load because port 8080 wasn’t allowed → fixed by updating security group.
Faced persistence issue after restarting container → solved using Docker volumes for data persistence.
Prometheus config required corrections (backend:8000 target) before it started working properly.
- Final Outcome
- Flask backend + frontend running in Docker
- Automated builds with CI/CD
- Monitoring & observability with Prometheus + Grafana
- Application accessible through public IP
Key Takeaways as a Fresher
Learned end-to-end DevOps workflow in a practical way.
Understood importance of ports, volumes, and container networking.
Gained confidence in setting up CI/CD pipelines and observability tools.
This project gave me a strong foundation and boosted my confidence to take on bigger challenges in DevOps. 🚀
Top comments (0)