Change where a secret may go
Gives a secret the hosts it may be sent to in place of those it had, and keeps its value: for whoever decides where a secret goes and does not hold the value. Rules that name it for a host it may no longer go to stay as they were written, and the node sends no request there with it (secret_host_not_allowed, in x-egress-proxy); what is given or changed after is held to the new hosts.
Takes admin.
https://api.glac.ai/v1/secrets/{name}Ủy quyền
Tham số đường dẫn
Tham số header
Thân yêu cầuJSONbắt buộc
Returns
200
The secret, without its value.
- allowed_hostsarray | nullrequired
The hosts a secret may be sent to, and no other: by
egress.injectto the host of its entry, and asimage_pull_secretto the registry of theimage(the registry's host as the reference writes it, without its port;docker.iofor a reference that names no registry). Each is a host name, or*.and a name for every name under it (not the name itself), asegress.allowwrites names: compared without case and without a trailing dot, kept in lower case, each once. No address and no port: a secret goes where the node has the server prove that it is the host named, and a host's ports are the host's. A rule's host that is a wildcard is covered only by a wildcard as wide or wider. null: the secret was given no hosts (every secret kept before secrets had hosts), and goes to none; an empty list goes to none either.
400
The request is not one this call takes. invalid_json: the body is not a JSON object; unknown_field: the body has a field this call does not take; unknown_parameter: the query has a parameter this call does not take; invalid_field: allowed_hosts is no list of host names, or an entry of it is no host name (param says which); invalid_name: the name in the path is not one a secret can have; missing_field: no allowed_hosts.
- exec_idoptionalstring
With
sandbox_movedofPOST …/run: the id of the command the call started and waited for, which goes on where the sandbox went: wait for it there through the control plane withGET …/exec/{exec_id}?wait_seconds=once the move is over. The same call made again starts the command a second time, unless it comes with the same Idempotency-Key.
401
missing_api_key, invalid_api_key, expired_api_key, invalid_token.
403
The credential may not do this. needs_api_key: a sandbox token cannot do this.
- exec_idoptionalstring
With
sandbox_movedofPOST …/run: the id of the command the call started and waited for, which goes on where the sandbox went: wait for it there through the control plane withGET …/exec/{exec_id}?wait_seconds=once the move is over. The same call made again starts the command a second time, unless it comes with the same Idempotency-Key.
404
Something the request names does not exist. secret_not_found: no such secret.
- exec_idoptionalstring
With
sandbox_movedofPOST …/run: the id of the command the call started and waited for, which goes on where the sandbox went: wait for it there through the control plane withGET …/exec/{exec_id}?wait_seconds=once the move is over. The same call made again starts the command a second time, unless it comes with the same Idempotency-Key.
default
Any other failure, in the same shape. internal (500): the node failed; the message says no more, and the node's log has the reason under the request's id. unavailable (503, retryable): no_capacity, every network slot of the node is in use; memory_full, a machine the call has to start (made, woken, booted from its disk, resumed, rolled back, built) does not fit in the host's memory beside what the machines that run on it are promised, and nothing paused or idle could be put to sleep to make room for it (memory of the node); drive_full, the call would have a template built and the node's data drive has no room for one (drive of the node); unavailable, the node is shutting down, the sandbox was still starting after 10 minutes, or it did not answer, or it is being moved to this node (with Retry-After: 1); fenced, the node's lease fences the sandbox (Node.lease). moved (409): the sandbox was moved to another node, which to names.
- exec_idoptionalstring
With
sandbox_movedofPOST …/run: the id of the command the call started and waited for, which goes on where the sandbox went: wait for it there through the control plane withGET …/exec/{exec_id}?wait_seconds=once the move is over. The same call made again starts the command a second time, unless it comes with the same Idempotency-Key.