ves-io-schema-k8s_pod_security_policy-API-List

Examples of listing k8spodsecurity_policy

Usecase:

List all k8spodsecurity_policys in current namespace

Request using vesctl:

vesctl configuration list k8s_pod_security_policy --namespace system

vesctl yaml response:

items:
- annotations: {}
  labels: {}
  name: pod-security-policy-1
  namespace: system
  statusSet: []
  tenant: acmecorp
  uid: c53eb063-d0e9-4471-a488-a2767892f895

Request using curl:

curl -X 'GET' -H 'X-Volterra-Useragent: v1/pgm=_tmp_go-build817539475_b001_apidocs.test/host=docker-desktop' 'https://acmecorp.console.ves.volterra.io/api/config/namespaces/system/k8s_pod_security_policys'

curl response

HTTP/1.1 200 OK
Content-Length: 447
Content-Type: application/json
Date: Mon, 22 Feb 2021 15:44:06 GMT
Vary: Accept-Encoding

{
  "items": [
    {
      "tenant": "acmecorp",
      "namespace": "system",
      "name": "pod-security-policy-1",
      "uid": "c53eb063-d0e9-4471-a488-a2767892f895",
      "description": "",
      "disabled": false,
      "labels": {
      },
      "annotations": {
      },
      "owner_view": null,
      "metadata": null,
      "system_metadata": null,
      "object": null,
      "get_spec": null,
      "status_set": [
      ]
    }
  ]
}