-
Notifications
You must be signed in to change notification settings - Fork 988
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
add field for PersistentVolumeClaim resource #2644
base: main
Are you sure you want to change the base?
Conversation
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.
although tests are passing it seems like we're missing two fields that are mentioned in the docs kind
and apiGroup
It looks like the PR is assuming that both kind and apiGroup are setup in a way that sets up the dataSource as PVC but from the docs users have the option to input their own values (though this is alpha something to note)
I'm thinking we should stick more with how the api and manifest is formatted meaning instead of
data_source {
persistent_volume_claim {
claim_name = "example-source-pvc"
}
}
we should do
data_source {
name = "example-source-pvc"
}
leaving the other fields as defaults but not part of the schema. once they are moved out of alpha we can add them in. This method would prevent any extra worked needed later on while also preventing some unexpected changes for users that would use this.
Hope this makes sense, let me know your thoughts!
1d6b7ac
to
9f7577f
Compare
@BBBmau The kind and apiGroup field is actually very important in the stable API. It is possible to specify the dataSource as either a VolumeSnapshot or a PVC. You need the kind field to differentiate in that case you have both with the same name. https://kubernetes.io/docs/concepts/storage/persistent-volumes/#create-persistent-volume-claim-from-volume-snapshot |
This makes sense, not sure how I glanced over that. Thanks for bringing it up. cc: @JaylonmcShan03 |
Description
Addresses #2608
This pull request introduces the
data_source
field for the PersistentVolumeClaim resource.Changes
data_source
field to the PersistentVolumeClaim schema.Create
function to ensure the specifieddata_source
PVC exists.Acceptance tests
Output from acceptance testing:
Release Note
Release note for CHANGELOG:
References
Community Note