A full-stack weather application with a React frontend and .NET 10 API backend, containerized for easy deployment to Synology NAS and other environments.
- React Frontend: Modern, responsive weather dashboard with Tailwind CSS
- .NET 10 API: Minimal Web API serving 5-day weather forecasts
- Docker Ready: Pre-configured for easy deployment
- Synology Compatible: Deploy directly to Synology Container Manager
- CORS Enabled: Frontend and API communication pre-configured
React-Codex-Demo/
βββ react-codex-demo/ # React frontend (Vite + TypeScript)
β βββ src/
β β βββ App.tsx # Main app component
β β βββ Weather.tsx # Weather forecast component
β β βββ main.tsx
β βββ package.json
β βββ vite.config.ts
β
βββ api/ # .NET 10 Minimal API
β βββ Program.cs # API setup and endpoints
β βββ WeatherApi.csproj # Project file
β βββ Properties/
β
βββ Dockerfile.api # .NET API container
βββ Dockerfile.frontend # React frontend container
βββ docker-compose.yml # Docker Compose config
βββ .dockerignore # Docker build excludes
βββ .env.example # Environment variables template
β
βββ QUICKSTART.md # Quick deployment guide
βββ DOCKER_DEPLOY.md # Detailed deployment guide
βββ README.md # This file
Frontend (React):
cd react-codex-demo
npm install
npm run dev
# Access at http://localhost:5173API (.NET):
cd api
dotnet restore
dotnet run
# Access at http://localhost:8080/api/weatherBuild and run locally:
# Windows
build-and-run.bat
# macOS/Linux
docker-compose up -dDeploy to Synology NAS: See QUICKSTART.md for step-by-step guide
GET /api/weather
Response:
[
{
"date": "2026-02-16",
"temperatureC": 22,
"temperatureF": 72,
"summary": "Mild"
},
...
]| Service | Port | Container | Image |
|---|---|---|---|
| Frontend | 3000 | weather-frontend | node:20-alpine |
| API | 8080 | weather-api | dotnet:10.0 |
- Both containers run on
weather-networkbridge - Frontend to API communication via internal
http://weather-api:8080 - Health check enabled on API (30s intervals)
- Node.js 20+
- .NET 10 SDK
- Docker & Docker Compose (for containerized deployment)
- Synology Container Manager installed
- 2GB+ free storage
- Network ports 3000 and 8080 available
See .env.example for configuration options:
ASPNETCORE_ENVIRONMENT=Production
ASPNETCORE_URLS=http://+:8080
REACT_APP_API_URL=http://weather-api:8080- QUICKSTART.md - 3-step deployment guide
- DOCKER_DEPLOY.md - Complete deployment documentation
- api/README.md - API-specific information
- Check Docker installation:
docker --version - Ensure ports 3000 and 8080 are available
- Review logs:
docker-compose logs
- Verify API container is running:
docker ps - Check REACT_APP_API_URL is set correctly
- Review browser console for CORS errors
See "Troubleshooting" section in DOCKER_DEPLOY.md
- React 18 - UI framework
- Vite - Build tool
- TypeScript - Type safety
- Tailwind CSS - Styling
- .NET 10 - Framework
- C# - Language
- Minimal APIs - API pattern
- CORS - Cross-origin support
- Docker - Containerization
- Docker Compose - Orchestration
- Alpine Linux - Lightweight base images
API:
cd api
dotnet publish -c Release -r win-arm64 --self-containedFrontend:
cd react-codex-demo
npm run build# Build all images
docker build -f Dockerfile.api -t weather-api:latest .
docker build -f Dockerfile.frontend -t weather-frontend:latest .
# Or use compose
docker-compose build- Change default ports if exposing to internet
- Use reverse proxy (nginx, traefik) for HTTPS
- Restrict API to trusted origins in CORS config
- Keep containers updated regularly
This project is an example Weather Dashboard application.
For deployment issues on Synology:
- Check QUICKSTART.md
- Review DOCKER_DEPLOY.md
- Check Container Manager logs for errors
- v1.0 (Feb 15, 2026) - Initial release with React frontend, .NET 10 API, Docker support
Happy forecasting! π€οΈ