mimir
mimir copied to clipboard
"The endpoint must not prefixed with the bucket name" error when bucket name matches beginning of S3 endpoint
Describe the bug
An undocumented consequence of PR #3414 is that users are not allowed to use a bucket name that matches the first subdomain on an s3 endpoint.
To Reproduce
I am using Ceph RGW to create an S3-compatible object gateway at mimir.rgw.jlh.name and a bucket named mimir. This bucket can be accessed at mimir.mimir.rgw.jlh.name or mimir.rgw.jlh.name/mimir. I use multiple RGW gateway, as different buckets may have different Ceph storage pool requirements. (e.g. ssd vs hdd)
I have configured mimir to use this bucket, but Mimir crashes with the error "error validating config: invalid rulestore config: the endpoint must not prefixed with the bucket name".
common:
storage:
backend: s3
s3:
bucket_name: "mimir"
endpoint: "mimir.rgw.jlh.name"
access_key_id: "${AWS_ACCESS_KEY_ID}"
secret_access_key: "${AWS_SECRET_ACCESS_KEY}"
blocks_storage:
storage_prefix: blocks
alertmanager_storage:
storage_prefix: alertmanager
ruler_storage:
storage_prefix: ruler
Expected behavior
This check breaks an otherwise valid configuration, which can be a minor annoyance for users. Perhaps it should should be removed or documentation should be added.
Environment
- Infrastructure: Kubernetes
- Deployment tool: mimir-distributed helm
Hi, I am interested to work on this issue
The check for the prefix was added on purpose so let's fix this via documenting the restriction 🙏
If you'd like to add documentation about this @samyakjain10 , I can assign the issue to you.
@56quarters I've updated the doc, could you please have a look
@56quarters, is there an existing docs PR that corresponds to this issue? If so, I'm happy to take a look. If not, I'm happy to draft one up 😄
@56quarters, is there an existing docs PR that corresponds to this issue? If so, I'm happy to take a look. If not, I'm happy to draft one up 😄
There is an existing PR and it looks like you're reviewing it right now!
haha, yes! I saw this after my comment yesterday! Thanks, @56quarters !