Open BeardDude opened 2 weeks ago
According to the S3 docs...
Bucket names can consist only of lowercase letters, numbers, dots (.), and hyphens (-).
True. The bucket name is bucket1 and the sub-folder name is config inside which i have the application-dev.yml file.
Is there any way to access the application-dev.yml file ?
Yes there is an example in the integration test we have https://github.com/spring-cloud/spring-cloud-config/blob/main/spring-cloud-config-server/src/test/java/org/springframework/cloud/config/server/AwsS3IntegrationTests.java#L94-L95
Issue Description:
I'm trying to access configuration files located inside a folder in an S3 bucket using Spring Cloud Config. Below is the folder structure in S3:
Here is the relevant Spring configuration:
When trying to access the configuration via
http://localhost:8888/application/dev
, I am encountering an issue. The debug logs indicate that the S3 key was not found. The encoded URL appears as/bucket1%2Fconfig/application-dev.yml
, and it seems like the folder structure or path encoding might be the cause.Debug Log Excerpt:
Question:
How can I resolve this issue to correctly access the
application-dev.yml
file from theconfig
folder in the S3 bucket?(or)
Support for subfolders in a S3 bucket is not available ?
Package versions:
spring-cloud-config-server - 4.1.3 software.amazon.awssdk (s3) - 2.28.1
Any help or suggestions would be appreciated!