jcaddel / maven-s3-wagon

Multi-threaded wagon to connect Maven with Amazon S3
123 stars 50 forks source link

configurable S3 endpoints #7

Open yegor256 opened 11 years ago

yegor256 commented 11 years ago

As far as I understand, at the moment, the plugin doesn't support any other S3 endpoints except s3, the default one. My bucket is in Singapour and its endpoint is s3-ap-southeast-1. Would be nice to make it possible to configure an end point. Maybe in settings.xml inside server element (http://maven.apache.org/settings.html#Servers):

<servers>
  <server>
    <id>server001</id>
    <username>my_login</username>
    <password>my_password</password>
    <configuration>
      <endpoint>s3-ap-southeast-1.amazonaws.com</endpoint>
    </configuration>
  </server>
</servers>
mdedetrich commented 8 years ago

This is basically required on our end, we are unable to use maven-s3-wagon at all due to not being able to configure the endpoint and our s3 repo sitting in the south-east asia region

mdedetrich commented 8 years ago

On our end, this isn't the actual issue. It turns out that the S3 client by default (since 1.4) automatically deals with buckets in different regions. In other words, regardless of what region your bucket is in, the S3 client will upload your files to correct bucket with the correct endpoint

In our case, the issue was that setting the default ACL (which with maven-s3-wagon was publicRead) was causing issues with private S3 buckets, hence the reason for this pull request https://github.com/jcaddel/maven-s3-wagon/pull/22

Faylixe commented 7 years ago

I have the same problem too, we would like to use Minio s3 server for storing artifact and configure s3-wagon to use Minio server URL as AWS endpoint.

jamshid commented 7 years ago

FYI @ankon added support for a maven.wagon.s3.endpoint property in pull request https://github.com/jcaddel/maven-s3-wagon/pull/28/. Follow there, it does work but you need to build and host it.