generated from amazon-archives/__template_Apache-2.0
-
Notifications
You must be signed in to change notification settings - Fork 271
Closed
Description
Description
ACK S3 controller doesn't require filter field or prefix field to exist in the manifest when creating LifecycleRule. AWS API doc assumes that either filter or prefix exists - See Filter description for more details here - https://docs.aws.amazon.com/AmazonS3/latest/API/API_LifecycleRule.html
Steps to reproduce
- Create following manifest file:
apiVersion: s3.services.k8s.aws/v1alpha1
kind: Bucket
metadata:
name: test-random-name-bucket
spec:
name: test-random-name-bucket
lifecycle:
rules:
- id: NoncurrentVersion
# filter:
# prefix: logs/
status: Enabled
noncurrentVersionTransitions:
- noncurrentDays: 30
storageClass: STANDARD_IA
tagging:
tagSet:
- key: "Name"
value: "test-random-name-bucket"
- Apply this manifest on your cluster with S3 controller installed
- See what happens:
- You will get bucket get 'created' response,
- bucket will be created without lifecycle rules,
kubectl get buckets test-random-name-bucket -o yamlwill show 'api error MalformedXML: The XML you provided was not well-formed or did not validate against our published schema'
Expected outcome
Should fail on schema validation and directly respond to user.
Environment
- Kubernetes version: v1.33.4-eks-e386d34
- Using EKS with Platform version eks.12
- AWS service targeted - S3
Metadata
Metadata
Assignees
Labels
No labels