Admin Access
このコンテンツはまだ日本語訳がありません。
Admin Access
Section titled “Admin Access”The Greentic admin API is a secure runtime control surface exposed by greentic-start.
It is used for:
- health and runtime status checks
- listing active runtimes and admin client CNs
- stopping a runtime
- adding and removing allowed admin client CNs
Overview
Section titled “Overview”The admin API itself is cloud-agnostic.
What differs by target is the access path:
- AWS uses a local tunnel path
- Azure uses a public HTTPS admin relay path
- GCP uses a public HTTPS admin relay path
This keeps the runtime contract generic while letting the deploy layer materialize the access method for each cloud.
Available Commands
Section titled “Available Commands”The gtc admin surface currently supports:
gtc admin accessgtc admin certsgtc admin tokengtc admin healthgtc admin statusgtc admin listgtc admin adminsgtc admin stopgtc admin add-client --cn <NAME>gtc admin remove-client --cn <NAME>gtc admin tunnelfor AWS only
Access Models
Section titled “Access Models”AWS uses a local tunnel to the runtime-local admin listener.
Start the tunnel first:
gtc admin tunnel ./cloud-deploy-demo-bundle --target awsThen use the normal admin commands:
gtc admin health ./cloud-deploy-demo-bundle --target awsgtc admin status ./cloud-deploy-demo-bundle --target awsgtc admin admins ./cloud-deploy-demo-bundle --target awsAzure And GCP
Section titled “Azure And GCP”Azure and GCP use a public admin relay URL exposed by the deployed runtime.
The relay:
- accepts a bearer token on the public side
- forwards internally to the local admin server
- keeps the actual admin server on the runtime-local listener
Use the same gtc admin commands directly:
gtc admin access ./cloud-deploy-demo-bundle --target azuregtc admin health ./cloud-deploy-demo-bundle --target azuregtc admin status ./cloud-deploy-demo-bundle --target azuregtc admin access ./cloud-deploy-demo-bundle --target gcpgtc admin health ./cloud-deploy-demo-bundle --target gcpgtc admin status ./cloud-deploy-demo-bundle --target gcpTypical Usage
Section titled “Typical Usage”1. Inspect The Access Plan
Section titled “1. Inspect The Access Plan”gtc admin access ./cloud-deploy-demo-bundle --target gcpThis shows the current admin access model and the public endpoint when one exists.
2. Run A Health Check
Section titled “2. Run A Health Check”gtc admin health ./cloud-deploy-demo-bundle --target gcpExpected result:
- HTTP
200 {"data":"healthy","success":true}
3. Read Runtime Status
Section titled “3. Read Runtime Status”gtc admin status ./cloud-deploy-demo-bundle --target gcp4. Inspect Current Admin Client CNs
Section titled “4. Inspect Current Admin Client CNs”gtc admin admins ./cloud-deploy-demo-bundle --target gcp5. Add Or Remove An Allowed Client CN
Section titled “5. Add Or Remove An Allowed Client CN”gtc admin add-client ./cloud-deploy-demo-bundle --target gcp --cn ops-admingtc admin remove-client ./cloud-deploy-demo-bundle --target gcp --cn ops-admin6. Stop A Runtime
Section titled “6. Stop A Runtime”gtc admin stop ./cloud-deploy-demo-bundle --target gcpManual Token And Certificate Access
Section titled “Manual Token And Certificate Access”You can also materialize the raw credentials if you need them for debugging.
Relay Token
Section titled “Relay Token”For Azure and GCP:
gtc admin token ./cloud-deploy-demo-bundle --target gcpAdmin Client Certificates
Section titled “Admin Client Certificates”For any target:
gtc admin certs ./cloud-deploy-demo-bundle --target gcpThis writes the local admin certificate material under the bundle’s .greentic/admin/certs/ directory.
Manual Relay Probe
Section titled “Manual Relay Probe”For Azure and GCP, you can call the relay endpoint directly if needed.
TOKEN="$(gtc admin token ./cloud-deploy-demo-bundle --target gcp)"ENDPOINT="$(gtc admin access ./cloud-deploy-demo-bundle --target gcp --output json | jq -r .admin_public_endpoint)"
curl -i \ -H "Authorization: Bearer ${TOKEN}" \ "${ENDPOINT}/health"gtcstays an orchestration layer. It does not own cloud-specific deploy semantics.greentic-startowns the generic admin API and relay behavior.greentic-deployerowns how each cloud target materializes access to that admin API.destroydoes not require special handling for the admin relay resources. They live in the same Terraform graph and are removed through the normal destroy path.