ves-io-schema-kms_policy-API-Replace

Examples of replacing kms_policy

Usecase:

Replace kms-policy-1

Request using vesctl:

vesctl configuration replace kms_policy -i kms_policy.yaml

where file kmspolicy.yaml has following contents (kmspolicy.ReplaceRequest):

metadata:
  name: kms-policy-1
  namespace: documentation
spec:
  rules:
  - kind: kms_policy_rule
    name: kms-policy-rule-2

vesctl yaml response: None

Request using curl:

curl -X 'PUT' -d '{"metadata":{"name":"kms-policy-1","namespace":"documentation"},"spec":{"rules":[{"kind":"kms_policy_rule","name":"kms-policy-rule-2"}]}}' -H 'X-Volterra-Useragent: v1/pgm=_tmp_go-build743694289_b001_apidocs.test/host=docker-desktop' 'https://acmecorp.console.ves.volterra.io/api/kms/namespaces/documentation/kms_policys/kms-policy-1'

curl response:

HTTP/1.1 200 OK
Content-Length: 4
Content-Type: application/json
Date: Thu, 02 Jul 2020 15:53:10 GMT
Vary: Accept-Encoding

{

}