Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

promote KMSAutokeyConfgi to Beta #2

Merged
merged 3 commits into from
Nov 18, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -18,8 +18,8 @@ metadata:
name: kmsautokeyconfig-sample
spec:
folderRef:
# Replace "${FOLDER_ID?}" with the numeric ID for your folder on which you want to configure autokey.
external: "${FOLDER_ID?}"
# Replace "${TEST_FOLDER_ID}" with the numeric ID for your folder on which you want to configure autokey.
external: folders/${FOLDER_ID?}
keyProject:
# Replace ${PROJECT_ID?} with your kms project ID where kms keys will be automatically created.
external: "${PROJECT_ID?}"
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
apiVersion: kms.cnrm.cloud.google.com/v1beta1
kind: KMSAutokeyConfig
metadata:
annotations:
cnrm.cloud.google.com/management-conflict-prevention-policy: none
finalizers:
- cnrm.cloud.google.com/finalizer
- cnrm.cloud.google.com/deletion-defender
generation: 2
labels:
cnrm-test: "true"
name: autokeyconfig-${uniqueId}
namespace: ${uniqueId}
spec:
folderRef:
external: folders/123451001
keyProject:
external: projects/diff-{uniqueId}
status:
conditions:
- lastTransitionTime: "1970-01-01T00:00:00Z"
message: The resource is up to date
reason: UpToDate
status: "True"
type: Ready
externalRef: folders/123451001/autokeyConfig
observedGeneration: 2
observedState:
state: ACTIVE
Original file line number Diff line number Diff line change
@@ -0,0 +1,125 @@
GET https://cloudkms.googleapis.com/v1/folders/${folderID}/autokeyConfig?%24alt=json%3Benum-encoding%3Dint
Content-Type: application/json
User-Agent: kcc/controller-manager
x-goog-request-params: name=folders%2F${folderID}%2FautokeyConfig

200 OK
Cache-Control: private
Content-Type: application/json; charset=UTF-8
Server: ESF
Vary: Origin
Vary: X-Origin
Vary: Referer
X-Content-Type-Options: nosniff
X-Frame-Options: SAMEORIGIN
X-Xss-Protection: 0

{
"state": 3
}

---

PATCH https://cloudkms.googleapis.com/v1/folders/${folderID}/autokeyConfig?%24alt=json%3Benum-encoding%3Dint&updateMask=keyProject
Content-Type: application/json
User-Agent: kcc/controller-manager
x-goog-request-params: autokey_config.name=folders%2F${folderID}%2FautokeyConfig

{
"keyProject": "projects/${uniqueId}",
"name": "folders/${folderID}/autokeyConfig"
}

200 OK
Cache-Control: private
Content-Type: application/json; charset=UTF-8
Server: ESF
Vary: Origin
Vary: X-Origin
Vary: Referer
X-Content-Type-Options: nosniff
X-Frame-Options: SAMEORIGIN
X-Xss-Protection: 0

{
"keyProject": "projects/${uniqueId}",
"name": "folders/${folderID}/autokeyConfig",
"state": 1
}

---

GET https://cloudkms.googleapis.com/v1/folders/${folderID}/autokeyConfig?%24alt=json%3Benum-encoding%3Dint
Content-Type: application/json
User-Agent: kcc/controller-manager
x-goog-request-params: name=folders%2F${folderID}%2FautokeyConfig

200 OK
Cache-Control: private
Content-Type: application/json; charset=UTF-8
Server: ESF
Vary: Origin
Vary: X-Origin
Vary: Referer
X-Content-Type-Options: nosniff
X-Frame-Options: SAMEORIGIN
X-Xss-Protection: 0

{
"keyProject": "projects/${uniqueId}",
"name": "folders/${folderID}/autokeyConfig",
"state": 1
}

---

PATCH https://cloudkms.googleapis.com/v1/folders/${folderID}/autokeyConfig?%24alt=json%3Benum-encoding%3Dint&updateMask=keyProject
Content-Type: application/json
User-Agent: kcc/controller-manager
x-goog-request-params: autokey_config.name=folders%2F${folderID}%2FautokeyConfig

{
"keyProject": "projects/diff-{uniqueId}",
"name": "folders/${folderID}/autokeyConfig"
}

200 OK
Cache-Control: private
Content-Type: application/json; charset=UTF-8
Server: ESF
Vary: Origin
Vary: X-Origin
Vary: Referer
X-Content-Type-Options: nosniff
X-Frame-Options: SAMEORIGIN
X-Xss-Protection: 0

{
"keyProject": "projects/diff-{uniqueId}",
"name": "folders/${folderID}/autokeyConfig",
"state": 1
}

---

GET https://cloudkms.googleapis.com/v1/folders/${folderID}/autokeyConfig?%24alt=json%3Benum-encoding%3Dint
Content-Type: application/json
User-Agent: kcc/controller-manager
x-goog-request-params: name=folders%2F${folderID}%2FautokeyConfig

200 OK
Cache-Control: private
Content-Type: application/json; charset=UTF-8
Server: ESF
Vary: Origin
Vary: X-Origin
Vary: Referer
X-Content-Type-Options: nosniff
X-Frame-Options: SAMEORIGIN
X-Xss-Protection: 0

{
"keyProject": "projects/diff-{uniqueId}",
"name": "folders/${folderID}/autokeyConfig",
"state": 1
}
Loading