Minimal ASP.NET Core Web API demonstrating Swagger (OpenAPI) running in Docker.
This repository is intended as a small, real-world example showing:
- how to create a simple ASP.NET Core web service
- how to add Swagger via a NuGet package
- how to build and run the service using Docker and Docker Compose
- ASP.NET Core (.NET 8)
- Swagger UI (OpenAPI) via
Swashbuckle.AspNetCore - Docker multi-stage build
- Docker Compose setup
- Minimal API style
docker compose up --buildThe API will be available at:
- Hello endpoint: http://localhost:8080
- Health endpoint: http://localhost:8080/health
- Swagger UI: http://localhost:8080/swagger