8 lines
422 B
Bash
Executable File
8 lines
422 B
Bash
Executable File
#!/usr/bin/env bash
|
|
# mock-ci-register <name> — stands in for `docker exec peppa-act-runner peppa-runner-register`
|
|
# (PEPPA_CI_REGISTER_BIN). Same contract: token in PEPPA_RUNNER_TOKEN, name as the argument.
|
|
set -euo pipefail
|
|
: "${PEPPA_RUNNER_TOKEN:?PEPPA_RUNNER_TOKEN is required}"
|
|
printf '{"name":"%s","token":"%s"}\n' "$1" "$PEPPA_RUNNER_TOKEN" >> "${PEPPA_HOME:?}/mock-ci-register.jsonl"
|
|
echo "registered peppa-$1"
|