Merge branch 'feature/stage-reset-job' into 'main'
Fix reset_stage job to read STAGE_URL from environment See merge request esv/bsf/bsf-integration/orchard/orchard-mvp!38
This commit is contained in:
@@ -161,11 +161,16 @@ reset_stage:
|
|||||||
python - <<'RESET_SCRIPT'
|
python - <<'RESET_SCRIPT'
|
||||||
import httpx
|
import httpx
|
||||||
import sys
|
import sys
|
||||||
|
import os
|
||||||
|
|
||||||
BASE_URL = "${STAGE_URL}"
|
BASE_URL = os.environ.get("STAGE_URL", "")
|
||||||
ADMIN_USER = "admin"
|
ADMIN_USER = "admin"
|
||||||
ADMIN_PASS = "changeme123" # Default admin password
|
ADMIN_PASS = "changeme123" # Default admin password
|
||||||
|
|
||||||
|
if not BASE_URL:
|
||||||
|
print("ERROR: STAGE_URL environment variable not set")
|
||||||
|
sys.exit(1)
|
||||||
|
|
||||||
print(f"=== Resetting stage environment at {BASE_URL} ===")
|
print(f"=== Resetting stage environment at {BASE_URL} ===")
|
||||||
|
|
||||||
client = httpx.Client(base_url=BASE_URL, timeout=60.0)
|
client = httpx.Client(base_url=BASE_URL, timeout=60.0)
|
||||||
|
|||||||
Reference in New Issue
Block a user