Co-authored-by: xiuting.xu <xiutingxt.xu@gmail.com> Reviewed-on: #21 Reviewed-by: huhy <husteryezi@163.com> Reviewed-by: sundapeng <sundp@mail.zgclab.edu.cn> Reviewed-by: yuyr <yuyr@zgclab.edu.cn>
11 lines
414 B
Bash
11 lines
414 B
Bash
#!/usr/bin/env bash
|
||
set -euo pipefail
|
||
cd "$(dirname "$0")/.."
|
||
compose_cmd="docker compose"
|
||
if ! $compose_cmd version >/dev/null 2>&1; then
|
||
if command -v docker-compose >/dev/null 2>&1; then compose_cmd="docker-compose"; else
|
||
echo "需要 Docker Compose,请安装后重试" >&2; exit 1; fi
|
||
fi
|
||
$compose_cmd -p alert-mvp up -d --remove-orphans
|
||
echo "[OK] 服务已启动:Alertmanager http://localhost:9093"
|