Update shutdown commands to use lsof -ti for consistency

This commit is contained in:
Gabriel Radureau
2026-04-03 15:35:06 +02:00
parent 8103f64db9
commit f50de95f05

View File

@@ -182,7 +182,7 @@ curl -s http://localhost:8080/api/health
To stop the server gracefully: To stop the server gracefully:
```bash ```bash
# Send SIGTERM for graceful shutdown # Send SIGTERM for graceful shutdown
pkill -TERM -f "go run" kill -TERM $(lsof -ti :8080)
# Or send SIGINT (Ctrl+C equivalent) # Or send SIGINT (Ctrl+C equivalent)
pkill -INT -f "go run" pkill -INT -f "go run"
@@ -198,7 +198,7 @@ pkill -INT -f "go run"
For force stop (if graceful shutdown hangs): For force stop (if graceful shutdown hangs):
```bash ```bash
pkill -f "go" kill -9 $(lsof -ti :8080)
``` ```
**Verification:** **Verification:**
@@ -411,11 +411,8 @@ router.Route("/api/v1", func(r chi.Router) {
### Port Already in Use ### Port Already in Use
```bash ```bash
# Find process using port 8080 # Find and kill process using port 8080
lsof -i :8080 kill -TERM $(lsof -ti :8080)
# Kill the process
kill -9 <PID>
``` ```
### Server Not Responding ### Server Not Responding