Welcome to the Hackathon!
This repository contains boilerplate applications in PHP, Python, and multiple frontend frameworks.
Participants can choose any combination and run everything through Docker, without installing programming languages locally.
- Repository Structure
- Prerequisites
- Choosing Your Backend
- PHP Backend
- Python Backend
- Database (MySQL)
- Using a Frontend in Docker Compose
- Troubleshooting
hackathon2025/
boilerplate/
php/
python/
frontend/
react/
vue/
docker-compose_php.yml
docker-compose_python.yml
README.md
- Docker Desktop or Docker Engine
- Docker Compose v2+
Choose one backend:
- PHP →
docker-compose_php.yml - Python →
docker-compose_python.yml
Each backend includes:
- Backend service
- MySQL database
- Persistent storage
Run only the compose file for your chosen backend.
docker compose -f docker-compose_php.yml up --buildStarts:
- PHP backend
- MySQL database
Access backend:
http://localhost:8000
boilerplate/php/index.php
boilerplate/php/Controllers/
boilerplate/php/Models/
boilerplate/php/Services/
boilerplate/php/Repositories/
docker compose -f docker-compose_python.yml up --buildStarts FastAPI backend at:
http://localhost:8001
Live edits reload automatically.
Connection details:
| Setting | Value |
|---|---|
| Host | db |
| DB | hackathon |
| User | hackathon |
| Password | hackathon |
| Root Pass | root |
$pdo = new PDO(
'mysql:host=db;dbname=hackathon;charset=utf8mb4',
'hackathon',
'hackathon'
);import pymysql
conn = pymysql.connect(
host="db",
user="hackathon",
password="hackathon",
database="hackathon"
)Frontends live in:
boilerplate/frontend/react/
boilerplate/frontend/vue/
boilerplate/frontend/react/Dockerfile:
FROM node:20
WORKDIR /app
COPY package*.json ./
RUN npm install
COPY . .
CMD ["npm", "run", "dev", "--", "--host", "0.0.0.0", "--port", "5173"]PHP:
frontend:
build:
context: ./boilerplate/frontend/react
dockerfile: Dockerfile
volumes:
- ./boilerplate/frontend/react:/app
ports:
- "5173:5173"
depends_on:
- php-backendPython:
frontend:
build:
context: ./boilerplate/frontend/react
dockerfile: Dockerfile
volumes:
- ./boilerplate/frontend/react:/app
ports:
- "5173:5173"
depends_on:
- python-backenddocker compose -f docker-compose_php.yml up --buildor
docker compose -f docker-compose_python.yml up --buildFrontend runs at:
http://localhost:5173
Change ports in compose file.
docker compose logs dbEnsure vendor directory remains inside container.
Ensure app.py exists in:
boilerplate/python/