-
Notifications
You must be signed in to change notification settings - Fork 32
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Ensure ResourceSynced condition set (#4)
There really isn't an "active" or "available" status for Role resources in IAM. Basically, when the role is successfully created or updated, it's in sync with whatever the desired state of the role was. So, this patch adds simple setters after successful create and update code paths that ensures ResourceSynced condition of True is set on the Role CRs. Signed-off-by: Jay Pipes <[email protected]> By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.
- Loading branch information
Showing
11 changed files
with
72 additions
and
6 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,13 +1,13 @@ | ||
ack_generate_info: | ||
build_date: "2021-12-07T12:52:30Z" | ||
build_hash: 5ffa7aecf6b688da8c06f91bdc7b342ea2848c3f | ||
build_date: "2021-12-10T16:52:22Z" | ||
build_hash: 285d87b66b62fbfb859986ddf74c9f9b6ae743fb | ||
go_version: go1.17 | ||
version: v0.15.2 | ||
api_directory_checksum: d19cbe57322f73edfbc00516371d96a3e7f31c29 | ||
api_version: v1alpha1 | ||
aws_sdk_go_version: v1.40.2 | ||
generator_config_info: | ||
file_checksum: 08652a6d39a6e123f4895b062e6bbf04100a1955 | ||
file_checksum: 0e4f42c57dc98ab50fbc2c3450d2f841891e1936 | ||
original_file_name: generator.yaml | ||
last_modification: | ||
reason: API generation |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
{ | ||
"Version": "2012-10-17", | ||
"Statement": [ | ||
{ | ||
"Sid": "VisualEditor0", | ||
"Effect": "Allow", | ||
"Action": [ | ||
"iam:GetRole", | ||
"iam:CreateRole", | ||
"iam:DeleteRole", | ||
"iam:UpdateRole" | ||
], | ||
"Resource": "*" | ||
} | ||
] | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
// There really isn't a status of a role... it either exists or doesn't. If | ||
// we get here, that means the creation was successful and the desired | ||
// state of the role matches what we provided... | ||
ackcondition.SetSynced(&resource{ko}, corev1.ConditionTrue, nil, nil) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
// There really isn't a status of a role... it either exists or doesn't. If | ||
// we get here, that means the update was successful and the desired state | ||
// of the role matches what we provided... | ||
ackcondition.SetSynced(&resource{ko}, corev1.ConditionTrue, nil, nil) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1 @@ | ||
acktest @ git+https://github.com/aws-controllers-k8s/test-infra.git@8b21fd1a3374f506d35efe7426d5deed8b1bb1bf | ||
acktest @ git+https://github.com/aws-controllers-k8s/test-infra.git@75752b2 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters