This application uses a single-container architecture: the Express backend serves both the API and the frontend static files. No Nginx or separate frontend container is needed.
- Docker installed on your system
- Docker Compose (included with Docker Desktop)
# Build and start the container
docker compose up -d --build
# The application will be available at http://localhost:8080# Build the image
docker build -t github-stars-manager .
# Run the container
docker run -d -p 8080:3000 \
-v gsm-data:/app/data \
--name github-stars-manager \
github-stars-manager
# The application will be available at http://localhost:8080The Docker image is built in three stages:
- Frontend build: Installs npm dependencies and runs
vite buildto produce static files. - Backend build: Installs server dependencies and compiles TypeScript to JavaScript.
- Production: Copies backend code + frontend static files into a slim
node:22-alpineimage. Express serves everything on port 3000.
| Variable | Required | Description |
|---|---|---|
API_SECRET |
No | Bearer token for API authentication. If unset, auth is disabled. |
ENCRYPTION_KEY |
No | AES-256 key for encrypting stored secrets. Auto-generated if unset. |
Example with environment variables:
docker compose up -d --build
# Or with Docker directly
docker run -d -p 8080:3000 \
-e API_SECRET=my-secret-token \
-e ENCRYPTION_KEY=my-encryption-key \
-v gsm-data:/app/data \
--name github-stars-manager \
github-stars-managerSQLite database and encryption keys are stored in /app/data inside the container. The docker-compose.yml mounts a named volume (app-data) to persist this data across container restarts.
If you are using 1Panel or another reverse proxy to bind a domain, simply point it to http://127.0.0.1:8080. No special headers or CORS configuration is needed — the application handles everything internally.
# With Docker Compose
docker compose down
# With Docker directly
docker stop github-stars-manager
docker rm github-stars-manager# Pull latest code, rebuild and restart
git pull
docker compose up -d --build