976f5238f8
- internal .env loader (real env wins) + strictly validated config struct - ULID package: 48-bit ms timestamp + 80-bit crypto randomness, sortable - HTTP server with recovery/request-id/trusted-proxy/access-log middleware - /healthz, /readyz (pluggable checkers), /metricsz (counter registry) - multi-stage Dockerfile (alpine, non-root) + compose with healthchecks, app bound to 127.0.0.1:8787, mongo unpublished, graceful 15s shutdown Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
33 lines
581 B
Makefile
33 lines
581 B
Makefile
GO ?= go
|
|
|
|
.PHONY: build run test test-integration lint seed smoke backup restore
|
|
|
|
build:
|
|
$(GO) build ./...
|
|
|
|
run:
|
|
$(GO) run ./cmd/app
|
|
|
|
test:
|
|
$(GO) test ./...
|
|
|
|
test-integration:
|
|
$(GO) test -tags=integration ./...
|
|
|
|
lint:
|
|
@unformatted=$$(gofmt -l .); if [ -n "$$unformatted" ]; then \
|
|
echo "gofmt needed on:"; echo "$$unformatted"; exit 1; fi
|
|
$(GO) vet ./...
|
|
|
|
seed:
|
|
@echo "seed script lands in phase 12 (scripts/seed.go)"; exit 1
|
|
|
|
smoke:
|
|
./scripts/smoke.sh
|
|
|
|
backup:
|
|
@echo "backup target lands in phase 12"; exit 1
|
|
|
|
restore:
|
|
@echo "restore target lands in phase 12"; exit 1
|