Least privilege
Scope the XC API token to the target namespace and resource operations. Use a separate token and protected environment for each deployment boundary.
เนื้อหานี้ยังไม่มีในภาษาของคุณ
Run validate on pull_request events without XC credentials. Run apply, create, update, or delete only after code reaches a protected branch or an explicitly approved deployment environment.
Do not expose XC secrets through pull_request_target, workflows checked out from forks, command-line arguments, or manifest files. Grant the workflow only contents: read unless another step has a documented need for more.
Least privilege
Scope the XC API token to the target namespace and resource operations. Use a separate token and protected environment for each deployment boundary.
Explicit inputs
Commit manifests or provide an inline declaration. The Action does not fetch manifest URLs or interpret standard input as a manifest source.
Isolated execution
xcsh is spawned directly with shell: false; file paths and values remain distinct process arguments and shell metacharacters are never evaluated.
Controlled results
Treat get, export, and aggregate result data as configuration. Limit artifact access and retention, and avoid printing live objects in public logs.
The default xcsh version and platform digests are committed in xcsh.lock.json. Before execution, the Action:
An exact version override resolves the same two digests through GitHub release metadata. Missing, duplicate, malformed, or mismatched metadata stops the step.
The Action masks api-token and github-token. It does not include credentials in result JSON, job summaries, cache keys, or command arguments. xcsh receives tenant credentials through this environment contract:
XCSH_API_URLXCSH_API_TOKENXCSH_NAMESPACEThe api-url, api-token, and namespace inputs populate those values. You may instead configure the same environment variables on the Action step.
delete is intentionally non-interactive. Use an explicit manifest or resource identity, start with dry-run: client, and require branch or environment controls before enabling mutation. A delete workflow must never broaden its target from user-controlled event data.