File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 1111 paths-ignore :
1212 - " **/*.md"
1313 - " CODEOWNERS"
14- - " Makefile"
1514 pull_request :
1615 branches : [ "main" ]
1716 paths-ignore :
1817 - " **/*.md"
1918 - " CODEOWNERS"
20- - " Makefile"
2119
2220jobs :
2321 mod-tidy :
Original file line number Diff line number Diff line change 1+ # Pin swag to the same version as Dockerfile (github.com/swaggo/swag/cmd/swag@v1.16.4).
12setup :
2- go get -u github.com/swaggo/swag/cmd/swag
3- go install github.com/swaggo/swag/cmd/swag@latest
3+ go install github.com/swaggo/swag/cmd/swag@v1.16.4
44 swag init -g ./cmd/server/main.go -o ./docs
5- go get -u github.com/swaggo/gin-swagger
6- go get -u github.com/swaggo/files
75
86build-docker :
97 docker compose build --no-cache
108
11- # Run API against local Docker DBs. Requires `.env` with JWT_SECRET_KEY and API_SECRET_KEY (see .env.example).
9+ # Run API against local Docker DBs. Requires `.env` for secrets and DB settings (see .env.example).
10+ # Only overrides service hostnames to localhost for containers started outside Compose.
1211# Optional: set GIN_MODE=release in `.env` for the same security middleware as Docker Compose.
1312run-local :
1413 docker start dockerPostgres
@@ -17,8 +16,7 @@ run-local:
1716 test -f .env || { echo >&2 " Missing .env — copy .env.example to .env and set secrets (>=32 bytes each)." ; exit 1; }
1817 set -euo pipefail; \
1918 set -a && . ./.env && set +a; \
20- export REDIS_HOST=localhost POSTGRES_HOST=localhost \
21- POSTGRES_DB=go_app_dev POSTGRES_USER=docker POSTGRES_PASSWORD=password POSTGRES_PORT=5435; \
19+ export REDIS_HOST=localhost POSTGRES_HOST=localhost; \
2220 go run cmd/server/main.go
2321
2422up :
You can’t perform that action at this time.
0 commit comments