Skip to content

Commit 7bb08d4

Browse files
committed
docs: clarify planned features and database initialization method
1 parent 81410da commit 7bb08d4

2 files changed

Lines changed: 28 additions & 29 deletions

File tree

.github/copilot-instructions.md

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,14 @@
11
# GitHub Copilot Instructions
22

3-
> **⚡ Token Efficiency Note**: This is a minimal pointer file (~500 tokens, auto-loaded by Copilot).
4-
> For complete operational details, reference: `#file:AGENTS.md` (~2,500 tokens, loaded on-demand)
3+
> **⚡ Token Efficiency Note**: This is a minimal pointer file (~500 tokens, auto-loaded by Copilot).
4+
> For complete operational details, reference: `#file:AGENTS.md` (~2,500 tokens, loaded on-demand)
55
> For specialized knowledge, use: `#file:SKILLS/<skill-name>/SKILL.md` (loaded on-demand when needed)
66
77
## 🎯 Quick Context
88

9-
**Project**: ASP.NET Core 8 REST API demonstrating layered architecture patterns
10-
**Stack**: .NET 8 (LTS) • EF Core 9 • SQLite • Docker • xUnit
11-
**Pattern**: Repository + Service Layer + AutoMapper + FluentValidation
9+
**Project**: ASP.NET Core 8 REST API demonstrating layered architecture patterns
10+
**Stack**: .NET 8 (LTS) • EF Core 9 • SQLite • Docker • xUnit
11+
**Pattern**: Repository + Service Layer + AutoMapper + FluentValidation
1212
**Philosophy**: Learning-focused PoC emphasizing clarity and best practices
1313

1414
## 📐 Core Conventions
@@ -22,7 +22,7 @@
2222

2323
## 🏗️ Architecture at a Glance
2424

25-
```
25+
```text
2626
Controller → Service → Repository → Database
2727
↓ ↓
2828
Validation Caching
@@ -68,8 +68,8 @@ docker compose up
6868

6969
## 📚 Need More Detail?
7070

71-
**For operational procedures**: Load `#file:AGENTS.md`
72-
**For Docker expertise**: Load `#file:SKILLS/docker-containerization/SKILL.md`
71+
**For operational procedures**: Load `#file:AGENTS.md`
72+
**For Docker expertise**: *(Planned)* `#file:SKILLS/docker-containerization/SKILL.md`
7373
**For testing patterns**: *(Planned)* `#file:SKILLS/testing-patterns/SKILL.md`
7474

7575
---

AGENTS.md

Lines changed: 20 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -18,13 +18,13 @@ dotnet build
1818

1919
# Run application
2020
dotnet run --project src/Dotnet.Samples.AspNetCore.WebApi
21-
# Server starts on http://localhost:5000 (HTTP) and https://localhost:5001 (HTTPS)
21+
# Server starts on https://localhost:9000
2222

2323
# View API documentation
24-
# Open https://localhost:5001/swagger in browser
24+
# Open https://localhost:9000/swagger in browser
2525

2626
# View health check
27-
curl https://localhost:5001/health
27+
curl https://localhost:9000/health
2828
```
2929

3030
## .NET Version
@@ -249,7 +249,7 @@ dotnet run --project src/Dotnet.Samples.AspNetCore.WebApi
249249

250250
## API Endpoints
251251

252-
**Base URL**: `https://localhost:5001`
252+
**Base URL**: `https://localhost:9000`
253253

254254
| Method | Path | Description |
255255
| ------ | ---- | ----------- |
@@ -266,8 +266,8 @@ dotnet run --project src/Dotnet.Samples.AspNetCore.WebApi
266266
### Port already in use
267267

268268
```bash
269-
# Kill process on port 5000/5001
270-
lsof -ti:5000,5001 | xargs kill -9
269+
# Kill process on port 9000
270+
lsof -ti:9000 | xargs kill -9
271271
```
272272

273273
### Restore/build failures
@@ -297,13 +297,12 @@ rm src/Dotnet.Samples.AspNetCore.WebApi/Storage/players.db
297297
### EF Core migration issues
298298

299299
```bash
300-
# List migrations
301-
dotnet ef migrations list --project src/Dotnet.Samples.AspNetCore.WebApi
300+
# This project uses EnsureCreated() for database initialization
301+
# Schema is automatically created on first run
302302

303-
# Apply migrations manually (usually auto-applied on startup)
304-
dotnet ef database update --project src/Dotnet.Samples.AspNetCore.WebApi
305-
306-
# Note: This project uses EnsureCreated(), not migrations
303+
# To reset the database, delete the SQLite file:
304+
rm src/Dotnet.Samples.AspNetCore.WebApi/Storage/players.db
305+
# Database will be recreated on next startup
307306
```
308307

309308
### SSL certificate issues (HTTPS)
@@ -313,7 +312,7 @@ dotnet ef database update --project src/Dotnet.Samples.AspNetCore.WebApi
313312
dotnet dev-certs https --trust
314313

315314
# Or use HTTP instead
316-
dotnet run --project src/Dotnet.Samples.AspNetCore.WebApi --urls "http://localhost:5000"
315+
dotnet run --project src/Dotnet.Samples.AspNetCore.WebApi --urls "http://localhost:9000"
317316
```
318317

319318
### Test failures
@@ -339,22 +338,22 @@ docker compose up
339338

340339
### Using Swagger UI (Recommended)
341340

342-
Open <https://localhost:5001/swagger> - Interactive documentation with "Try it out"
341+
Open <https://localhost:9000/swagger> - Interactive documentation with "Try it out"
343342

344343
### Using curl
345344

346345
```bash
347346
# Health check
348-
curl https://localhost:5001/health -k
347+
curl https://localhost:9000/health -k
349348

350349
# Get all players
351-
curl https://localhost:5001/players -k
350+
curl https://localhost:9000/players -k
352351

353352
# Get player by ID
354-
curl https://localhost:5001/players/1 -k
353+
curl https://localhost:9000/players/1 -k
355354

356355
# Create player
357-
curl -X POST https://localhost:5001/players -k \
356+
curl -X POST https://localhost:9000/players -k \
358357
-H "Content-Type: application/json" \
359358
-d '{
360359
"firstName": "Pele",
@@ -366,8 +365,8 @@ curl -X POST https://localhost:5001/players -k \
366365
}'
367366

368367
# Update player
369-
curl -X PUT https://localhost:5001/players/1 -k \
370-
-H "Content-Type: application/json" \
368+
curl -X PUT https://localhost:9000/players/1 -k
369+
-H "Content-Type: application/json"
371370
-d '{
372371
"firstName": "Diego",
373372
"lastName": "Maradona",
@@ -378,7 +377,7 @@ curl -X PUT https://localhost:5001/players/1 -k \
378377
}'
379378

380379
# Delete player
381-
curl -X DELETE https://localhost:5001/players/1 -k
380+
curl -X DELETE https://localhost:9000/players/1 -k
382381
```
383382

384383
**Note**: `-k` flag skips SSL certificate verification for self-signed development certificates.

0 commit comments

Comments
 (0)