a329d4906b
- 方案文档: AVCC 体系建设、IPTV TCS 需求(0-req)/PRD(1-prd)/任务(2-task)/二三四期任务 - tcs-iptv: Go 后端(哈希SDK/MA码生成/可信数据空间mock/业务编排/HTTP API+HMAC鉴权) - web-console: React+AntD 监管大屏(角色工作台/全流程演示/监管片库) - 一剧一码+集级哈希, 集级下架/恢复, 全栈测试通过
40 lines
685 B
Makefile
40 lines
685 B
Makefile
.PHONY: build test tidy run-api run-chain run-hash migrate db-check redis-check fmt vet
|
||
|
||
build:
|
||
go build ./...
|
||
|
||
test:
|
||
go test ./... -count=1
|
||
|
||
tidy:
|
||
go mod tidy
|
||
|
||
fmt:
|
||
gofmt -w .
|
||
|
||
vet:
|
||
go vet ./...
|
||
|
||
run-api:
|
||
go run ./cmd/api-svc
|
||
|
||
run-chain:
|
||
go run ./cmd/chain-svc
|
||
|
||
run-hash:
|
||
go run ./cmd/hash-api
|
||
|
||
# 本地依赖(直接使用本机已安装的 PostgreSQL / Redis,无需 Docker)
|
||
# psql 已加入 PATH(Postgres.app v16)
|
||
PG ?= psql
|
||
PG_DSN ?= postgres://postgres@localhost:5432/tcs_iptv?sslmode=disable
|
||
|
||
migrate:
|
||
@for f in deploy/migrations/*.sql; do echo "applying $$f"; $(PG) "$(PG_DSN)" -f $$f; done
|
||
|
||
db-check:
|
||
$(PG) "$(PG_DSN)" -c "\dt"
|
||
|
||
redis-check:
|
||
redis-cli ping
|