{"id":26452017,"url":"https://github.com/imamaaa/microservices-blogging-platform-with-docker-compose","last_synced_at":"2026-04-05T21:04:14.979Z","repository":{"id":282674832,"uuid":"949311601","full_name":"imamaaa/microservices-blogging-platform-with-docker-compose","owner":"imamaaa","description":"A microservices-based blogging platform using Flask, PostgreSQL, and Docker Compose. Features CRUD operations, database management via pgAdmin, and containerized deployment.","archived":false,"fork":false,"pushed_at":"2025-03-16T07:24:31.000Z","size":15,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-03-16T08:24:24.836Z","etag":null,"topics":["api-development","blogging-platform","containerization","docker","docker-compose","flask","microservices","postgresql","rest-api","web-application"],"latest_commit_sha":null,"homepage":"","language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/imamaaa.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2025-03-16T06:43:32.000Z","updated_at":"2025-03-16T07:27:59.000Z","dependencies_parsed_at":"2025-03-16T08:34:55.891Z","dependency_job_id":null,"html_url":"https://github.com/imamaaa/microservices-blogging-platform-with-docker-compose","commit_stats":null,"previous_names":["imamaaa/microservices-blogging-platform-with-docker-compose"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/imamaaa%2Fmicroservices-blogging-platform-with-docker-compose","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/imamaaa%2Fmicroservices-blogging-platform-with-docker-compose/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/imamaaa%2Fmicroservices-blogging-platform-with-docker-compose/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/imamaaa%2Fmicroservices-blogging-platform-with-docker-compose/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/imamaaa","download_url":"https://codeload.github.com/imamaaa/microservices-blogging-platform-with-docker-compose/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":244267637,"owners_count":20425867,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["api-development","blogging-platform","containerization","docker","docker-compose","flask","microservices","postgresql","rest-api","web-application"],"created_at":"2025-03-18T17:25:49.475Z","updated_at":"2025-12-30T22:12:59.327Z","avatar_url":"https://github.com/imamaaa.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Blogging Platform - Microservices Architecture\n\n[![Docker](https://img.shields.io/badge/Docker-%230db7ed.svg?style=for-the-badge\u0026logo=docker\u0026logoColor=white)](https://www.docker.com/)  \n[![Flask](https://img.shields.io/badge/Flask-%23000000.svg?style=for-the-badge\u0026logo=flask\u0026logoColor=white)](https://flask.palletsprojects.com/)  \n[![PostgreSQL](https://img.shields.io/badge/PostgreSQL-%23316192.svg?style=for-the-badge\u0026logo=postgresql\u0026logoColor=white)](https://www.postgresql.org/)  \n  \n\n## Overview\n\nThis project implements a microservices architecture for a blogging platform using Docker and Docker Compose. It consists of three key microservices:\n\n1. **pgAdmin**: A web-based interface for database administrators to manage the PostgreSQL database.\n2. **PostgreSQL**: A scalable database service that stores blog posts, user data, and transaction logs.\n3. **Flask Blog Application**: A web application that allows users to perform CRUD (Create, Read, Update, Delete) operations on blog posts.\n\nEach service runs in its own Docker container and is managed through Docker Compose for scalability and modularity.\n\n---\n\n## Architecture\n\n- **pgAdmin**: Runs on port `5050`, used for managing and querying the PostgreSQL database.\n- **PostgreSQL**: Runs on port `5432`, acting as the central storage for blog posts.\n- **Flask Blog Application**: Runs on port `8000`, provides API endpoints for interacting with the blog platform.\n\n---\n\n## Features\n\n- **Microservices-based** architecture for scalability \u0026 modularity.  \n- **RESTful API** for CRUD operations on blog posts.  \n- **PostgreSQL integration** for reliable data storage.  \n- **pgAdmin** for database queries and schema management.  \n- **Dockerized Deployment** using **Docker \u0026 Docker Compose**.  \n- **Secure \u0026 Scalable** with independent services. \n\n---\n\n## **Tech Stack**  \n| Technology     | Purpose |\n|---------------|---------|\n| **Flask**     | Backend Web Framework (Python) |\n| **PostgreSQL** | Database for storing blog data |\n| **pgAdmin**   | UI for PostgreSQL Management |\n| **Docker**    | Containerization |\n| **Docker Compose** | Service Orchestration |\n\n---\n\n## Prerequisites\n\n- [Docker](https://docs.docker.com/get-docker/) (must be installed)\n- [Docker Compose](https://docs.docker.com/compose/install/) (must be installed)\n- [Git](https://git-scm.com/book/en/v2/Getting-Started-Installing-Git) (for cloning the repository)\n\n---\n## Workflow  \n1. **User** interacts with the **Flask Blog API** to **create, read, update, and delete** posts.  \n2. **Flask App** communicates with **PostgreSQL** to **store and retrieve** blog data.  \n3. **pgAdmin** is available for **database queries and management**.  \n4. **All services** are **containerized** using **Docker** and managed with **Docker Compose**.  \n---\n\n## Getting Started  \n\n### 1️. Clone the Repository  \n```bash\ngit clone https://github.com/imamaaa/microservices-blogging-platform-with-docker-compose.git  \ncd microservices-blogging-platform-with-docker-compose\n```\n### 2️. Run the Microservices using Docker Compose\n```bash\ndocker-compose up --build -d\n```\nThis starts all services in detached mode ('-d').\n### 3️. Access the Services\n- Blog API → http://localhost:8000\n- pgAdmin → http://localhost:5050\n- PostgreSQL → Runs internally on localhost:5432\n---\n## API Endpoints  \n\n| Method | Endpoint       | Description          |\n|--------|--------------|----------------------|\n| GET    | `/posts`     | Get all posts        |\n| GET    | `/posts/\u003cid\u003e` | Get post by ID       |\n| POST   | `/posts`     | Create a new post    |\n| PUT    | `/posts/\u003cid\u003e` | Update a post        |\n| DELETE | `/posts/\u003cid\u003e` | Delete a post        |\n\n---\n## 📦 Deployment on Docker Hub\n\nIf you want to publish the Flask application as a Docker image:\n\n1️. **Build the Docker image:**  \n```bash\ndocker build -t YOUR_DOCKERHUB_USERNAME/blog-app .\n```\n2️. Push the image to Docker Hub:\n```bash\ndocker push YOUR_DOCKERHUB_USERNAME/blog-app\n```\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fimamaaa%2Fmicroservices-blogging-platform-with-docker-compose","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fimamaaa%2Fmicroservices-blogging-platform-with-docker-compose","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fimamaaa%2Fmicroservices-blogging-platform-with-docker-compose/lists"}