Repository navigation
|
Tried to setup using E.g. when I try to create a bucket it calls |
Answered by
0nkery
Aug 22, 2023
Replies: 3 comments 2 replies
|
Are you able to post a minimal example that reproduces your issue? Also, logging your app and then posting the logs is really helpful when debugging issues like this. Also, in case you haven't seen them already, we have localstack examples here. |
0 replies
|
UPD: It's not required, I could just use Solved the issue with this custom endpoint resolver: pub struct ForceBucketInPathResolver {
base_resolver: Endpoint,
}
impl ResolveEndpoint<aws_sdk_s3::config::endpoint::Params> for ForceBucketInPathResolver {
fn resolve_endpoint(&self, params: &aws_sdk_s3::config::endpoint::Params) -> aws_smithy_http::endpoint::Result {
match params.bucket() {
Some(bucket) => self.base_resolver.resolve_endpoint(params).map(|ep| {
let url = ep.url().to_owned();
ep.into_builder().url(format!("{url}{bucket}")).build()
}),
None => self.base_resolver.resolve_endpoint(params),
}
}
} |
2 replies
Answer selected by
0nkery
|
Hello! Reopening this discussion to make it searchable. |
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
UPD: It's not required, I could just use
builder.force_path_style(true)(thanks to rcoh).Solved the issue with this custom endpoint resolver: