Quick try with test account and get started
โ ๏ธ Disclaimer:
This project is an unofficial Pinterest clone created solely for educational purposes.
It is not affiliated with, endorsed by, or sponsored by Pinterest Inc.
Use responsibly and respect copyright and trademark laws.
- ๐ผ๏ธ Masonry grid feed with infinite scroll
- ๐ Search by query and tags
- ๐ Detailed pins with comments, likes, related pins
- ๐ Create/edit pins and boards
- ๐ค User profiles with followers/following
- ๐ฌ Real-time chat & notifications
- ๐ก SSE & WebSocket-powered updates
- ๐ง Smart recommendations based on user activity
- ๐ JWT & Google OAuth2
- โ๏ธ REST & GraphQL APIs
- ๐ฆ Dockerized with GitLab CI/CD
- ๐ Nginx Reverse Proxy/Security/Optimization
- Build your own image-sharing platform
- Learn modern full-stack development with Vue + FastAPI
- Use the project as a boilerplate for social media apps
- Practice advanced CI/CD & real-time data techniques
The feed is the main page featuring search and tags, displaying pins in the form of gifs, videos, and images. It shows users who have posted these pins. The layout follows a masonry grid design with infinite scrolling.
A detailed pin with title, description, href, tags, and the user who created it. Includes comments and likes. Below the pin, related pins are displayed based on connected tags.
Pin search by query and tags, with a quick search feature available on any page. It also displays popular pins and a list of recent searches.
Pin creation โ image/gif/video, with the option to add additional information to the pin and assign tags to it.
User profile โ profile editing by the owner, creation of boards, viewing/editing created/liked/saved pins, viewing/editing pins on boards. Users can also follow/unfollow and message other users.
By messaging another user, you create a chat where you can exchange messages and media in real time. Chats can be customized in terms of size and color. You can also see which users are online on the site or in the chat.
- FastAPI โ REST & GraphQL API
- SQLAlchemy โ ORM for database interactions
- Pydantic โ data validation & environment management
- JWT โ access/refresh tokens with revocation support
- OAuth2 โ Google authentication
- httpx โ interaction with external APIs
- FastAPI-Cache โ API-level caching
- FastAPI-Limiter โ API-level rate limiting
- FastAPI-Mail โ sending emails via FastAPI
- GraphQL (Strawberry) โ GraphQL API layer
- PostgreSQL, MySQL, MongoDB โ relational & non-relational databases
- Redis โ caching, token revocation, Celery broker/results, RedBeat
- Celery โ async tasks: email sending, image processing
- Celery Beat โ periodic tasks (e.g., promo emails)
- Redis Stream โ Consumer Groups, message streaming, background worker processing
- Redis pub/sub โ message passing between Celery and FastAPI
- RabbitMQ โ task and result passing between Celery and FastAPI
- RabbitMQ pub/sub โ message publication to exchange, queue subscription, SSE message transfer
- RabbitMQ stream โ message publishing and consumption from RabbitMQ queues
- WebSockets โ real-time chat with
FastAPI.websockets - SSE (Server-Sent Events) โ real-time notifications
- Asyncio, Aiofiles โ asynchronous operations
- Pytest โ testing framework
- Ruff โ linting & formatting
- Alembic โ database migrations
- Logging โ error logging (client-side, server-side, request logging)
- Sentry โ real-time error tracking, exception capturing, and performance monitoring
- Docker, Docker Compose โ containerization & orchestration
- Nginx โ reverse proxy with routing for API, WebSocket, Vue.js, SSE, and Prometheus with basic auth
- SSL โ secure HTTPS
- VPS โ deployment on virtual server
- GitLab CI/CD โ automated build, lint/format, migrations, test, deploy pipeline
- Yandex S3 โ media file storage (Yandex Object Storage)
- Prometheus โ monitoring & metrics collection for FastAPI, VPS (via node-exporter), and Nginx (via nginx-exporter)
- Grafana โ visualization of metrics collected by Prometheus for monitoring system performance and health
- Loki โ centralized log aggregation system for collecting logs
- Promtail โ agent for gathering and shipping logs to Loki
- Vue 3 โ modern JavaScript frontend framework
- Pinia โ state management
- Vue Router โ routing
- Tailwind CSS โ utility-first CSS framework
- Axios โ HTTP client
This project uses GitLab CI/CD to automate the entire delivery process. The pipeline includes the following stages:
-
๐งฎ Check Disk Space
Before anything starts, it checks available disk space. If it's less than 3 GB, it automatically runsdocker system pruneto free space. -
๐ณ Docker Build
Builds separate Docker images for:- FastAPI backend (
Dockerfile-fastapi) - Vue 3 frontend (
Dockerfile-vuejs)
- FastAPI backend (
-
โ Lint & Format
- Runs
ruff checkto detect linting issues. - Runs
ruff format --checkto ensure formatting consistency.
- Runs
-
๐ ๏ธ Database Migrations
- Applies PostgreSQL migrations via
alembic upgrade head. - Initializes MySQL database via custom script (
app.mysql.init_db).
- Applies PostgreSQL migrations via
-
๐งช Testing
Runspytestinside a container. -
๐ Deploy
Usesdocker-compose up -dto start all services after successful testing.
๐ Secrets & Env Handling:
Before any job runs, the pipeline copies environment variables from a predefined ${ENV} file and exports them for the scripts.
You can view the complete CI/CD configuration in .gitlab-ci.yml.
Have suggestions or improvements for the project? Feel free to discuss them in the Discussion section!
MIT License โ free to use & share!
Feel free to reach out if you have any questions, suggestions, or collaboration ideas:
- Email: dankupr21@gmail.com
- Telegram: @daniilkupryianchyk
- Linkedin: daniil-kupryianchyk













