Поднять API в нескольких репликах за HAProxy и добавить скрипты отказа реплики и rolling update
This commit is contained in:
@@ -34,7 +34,7 @@ test-failover:
|
||||
# ---------------------------------------------------------------------------
|
||||
EVIDENCE_DIR ?= evidence
|
||||
|
||||
.PHONY: build vet unit secrets up down destroy logs concurrency explain
|
||||
.PHONY: build vet unit secrets up down destroy logs concurrency explain instances rollout
|
||||
|
||||
build:
|
||||
go build -o bin/server ./cmd/server
|
||||
@@ -63,6 +63,15 @@ destroy:
|
||||
logs:
|
||||
docker compose logs
|
||||
|
||||
# Which container answers under which X-Instance-Id.
|
||||
instances:
|
||||
sh scripts/instances.sh
|
||||
|
||||
# Replaces every API replica with one built from the current sources, without
|
||||
# downtime; restore a replica stopped by stop-one with `docker compose start api`.
|
||||
rollout:
|
||||
sh scripts/rollout.sh
|
||||
|
||||
concurrency:
|
||||
go run ./tools/concurrency --base-url "$(BASE_URL)" --output "$(EVIDENCE_DIR)/concurrency.json"
|
||||
|
||||
|
||||
Reference in New Issue
Block a user