-
Notifications
You must be signed in to change notification settings - Fork 380
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
Move all IAM resources to iam
group and bump all of them to v1beta1
#996
Move all IAM resources to iam
group and bump all of them to v1beta1
#996
Conversation
d3524b6
to
94ef0d7
Compare
It's ready to review now. I've tested it with instructions in |
Tested the composition part of the guide with the following artifacts: apiVersion: apiextensions.crossplane.io/v1
kind: CompositeResourceDefinition
metadata:
name: xpostgresqlinstances.database.example.org
spec:
group: database.example.org
names:
kind: XPostgreSQLInstance
plural: xpostgresqlinstances
claimNames:
kind: PostgreSQLInstance
plural: postgresqlinstances
versions:
- name: v1alpha1
served: true
referenceable: true
schema:
openAPIV3Schema:
type: object
properties:
spec:
type: object
properties:
parameters:
type: object
properties:
storageGB:
type: integer
---
apiVersion: apiextensions.crossplane.io/v1
kind: Composition
metadata:
name: xpostgresqlinstances.aws.database.example.org
labels:
provider: aws
guide: quickstart
vpc: default
spec:
writeConnectionSecretsToNamespace: crossplane-system
compositeTypeRef:
apiVersion: database.example.org/v1alpha1
kind: XPostgreSQLInstance
resources:
- name: user
base:
apiVersion: identity.aws.crossplane.io/v1alpha1
kind: IAMUser
spec:
forProvider:
tags:
- key: k1
value: v1
providerConfigRef:
name: example
- name: key
base:
apiVersion: identity.aws.crossplane.io/v1alpha1
kind: IAMAccessKey
spec:
forProvider:
userNameSelector:
matchControllerRef: true
providerConfigRef:
name: example
writeConnectionSecretToRef:
name: access-key-secret
namespace: crossplane-system
- name: role
base:
apiVersion: identity.aws.crossplane.io/v1beta1
kind: IAMRole
spec:
forProvider:
assumeRolePolicyDocument: |-
{
"Version": "2012-10-17",
"Statement": [
{
"Effect": "Allow",
"Principal": {
"Service": [
"ec2.amazonaws.com",
"eks.amazonaws.com",
"eks-fargate-pods.amazonaws.com",
"lambda.amazonaws.com",
"s3.amazonaws.com"
]
},
"Action": [
"sts:AssumeRole"
]
}
]
}
tags:
- key: k1
value: v1
providerConfigRef:
name: example Claim: apiVersion: database.example.org/v1alpha1
kind: PostgreSQLInstance
metadata:
name: muvafclaim
namespace: default
spec: {} Once all all got ready, I followed the guide and successfully migrated to the new APIs. |
…e users time to migrate Signed-off-by: Muvaffak Onus <[email protected]>
Signed-off-by: Muvaffak Onus <[email protected]>
Signed-off-by: Muvaffak Onus <[email protected]>
Signed-off-by: Muvaffak Onus <[email protected]>
Signed-off-by: Muvaffak Onus <[email protected]>
…licyAttachment Signed-off-by: Muvaffak Onus <[email protected]>
…mbership Signed-off-by: Muvaffak Onus <[email protected]>
…yAttachment Signed-off-by: Muvaffak Onus <[email protected]>
Signed-off-by: Muvaffak Onus <[email protected]>
Signed-off-by: Muvaffak Onus <[email protected]>
Signed-off-by: Muvaffak Onus <[email protected]>
…yAttachment Signed-off-by: Muvaffak Onus <[email protected]>
…d their controllers similar to v1alpha1 ones to reduce the risk of something going wrong during migration Signed-off-by: Muvaffak Onus <[email protected]>
Signed-off-by: Muvaffak Onus <[email protected]>
Signed-off-by: Muvaffak Onus <[email protected]>
d16a0e1
to
999eddd
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
tested all of IAM ressource also via Composition looks great to me - LGTM
thanks for rebase ACM/ACMPCA stuff to get rid of master issues with check-diff ;)
Thanks a lot @haarchri !! |
…e-3.x Update alpine Docker tag to v3.18.5
Description of your changes
The ones already on
v1beta1
are kept as is with deprecation notice to not break users. Allv1alpha1
ones are moved toiam
group fromidentity
andIAM
prefix is dropped from their kind name.User impact of this change will be that users will still have the old CRs in their clusters but there won't be a controller reconciling them. Re-creating the exact same resource with new group and kind will be the migration path.
This PR involves a lot of surgery, I tried my best to keep commits contained to one action for easier review.
Fixes #989
I have:
make reviewable test
to ensure this PR is ready for review.How has this code been tested
By following
cluster/UPGRADE.md
instructions that are added by this PR.