generated from coulomb/repo-seed
Add credentialed E2B and Modal extensions, burst routing fallback, fin-hub meter export hook, BYOK docs, and 77 tests.
32 lines
840 B
Bash
Executable File
32 lines
840 B
Bash
Executable File
#!/usr/bin/env bash
|
|
# Operator smoke for cloud adapters — requires provider credentials.
|
|
set -euo pipefail
|
|
|
|
PROVIDER="${1:-e2b}"
|
|
case "$PROVIDER" in
|
|
e2b)
|
|
PROFILE="profile.e2b-burst"
|
|
if [[ -z "${E2B_API_KEY:-}" ]]; then
|
|
echo "E2B_API_KEY not set — skipping live smoke" >&2
|
|
exit 0
|
|
fi
|
|
;;
|
|
modal)
|
|
PROFILE="profile.modal-gpu"
|
|
if [[ -z "${MODAL_TOKEN_ID:-}" ]]; then
|
|
echo "MODAL_TOKEN_ID not set — skipping live smoke" >&2
|
|
exit 0
|
|
fi
|
|
;;
|
|
*)
|
|
echo "Usage: $0 [e2b|modal]" >&2
|
|
exit 1
|
|
;;
|
|
esac
|
|
|
|
echo "Smoke: sandboxer create --profile $PROFILE"
|
|
STATUS=$(sandboxer create --profile "$PROFILE" --project sand-boxer)
|
|
ID=$(echo "$STATUS" | python3 -c "import sys,json; print(json.load(sys.stdin)['sandbox_id'])")
|
|
echo "Created: $ID"
|
|
sandboxer destroy "$ID"
|
|
echo "Destroyed: $ID" |