Skip to content
This repository has been archived by the owner on Apr 30, 2019. It is now read-only.

Endpoint Support #4

Closed
serialx opened this issue Mar 5, 2013 · 6 comments
Closed

Endpoint Support #4

serialx opened this issue Mar 5, 2013 · 6 comments

Comments

@serialx
Copy link

serialx commented Mar 5, 2013

I currently use Japan S3 bucket and this plugin does not support uploading to S3 repos other than the standard US S3 buckets.

[ERROR] Failed to execute goal org.apache.maven.plugins:maven-deploy-plugin:2.5:deploy (default-deploy) on project aaaa: Failed to deploy artifacts: Could not transfer artifact com.aaaa:aaaa:war:1.0.0 from/to devsisters (s3://aaaa/): Cannot write directory 'com/': The bucket you are attempting to access must be addressed using the specified endpoint. Please send all future requests to this endpoint. -> [Help 1]
@nebhale
Copy link
Contributor

nebhale commented Mar 7, 2013

I'll take a look at this in a bit and get a fix out. Thanks for letting me know.

@ghost ghost assigned nebhale Mar 8, 2013
nebhale added a commit that referenced this issue Mar 8, 2013
Previously, if a bucket from a non-US region was accessed, a failure
would occur.  Now, the wagon attempts to determine what endpoint the
bucket should be accessed at, and then uses that endpoint for all
future access.  In order to determine the endpoint of a bucket, you
must have provided credentials that are privileged enough to read the
metadata of that bucket.

Closes issue #4
@nebhale
Copy link
Contributor

nebhale commented Mar 8, 2013

This should be fixed in 4.5.0.RELEASE which will show up shortly in various repositories. Please take note of the caveat about credentials in the commit log (I'm betting that you're already configured properly for this to work), and let me know if you've got any problems with it.

@nebhale nebhale closed this as completed Mar 8, 2013
@koppor
Copy link

koppor commented Nov 14, 2013

Works in 4.8.0.RELEASE with CNames configuration. Users should update from 4.5.0.RELEASE

@jamshid
Copy link

jamshid commented Jun 11, 2017

@koppor sorry I know this is old but do you happen to remember what you mean by "CNames configuration"?

I was hoping aws-maven lets you configure the endpoint directly, making requests to https://mybucket.example.com/snapshots when pom.xml has

      <url>s3://mybucket.example.com/snpashots</url>

This way it could publish to any S3-compatible storage system, not only AWS. The bucket name just needs a CNAME DNS record that points to the S3-compatible server. But aws-maven always uses url https://<bucket>.s3.amazonaws.com.

Seems it would be easy to add an option to use the <url> directly below. But this plugin has not been updated in years, maybe there's another one that allow configuration of the S3 endpoint?
https://github.com/spring-projects/aws-maven/blob/cc85d4d967234c301a61cdda9d32de358955b0f2/src/main/java/org/springframework/build/aws/maven/SimpleStorageServiceWagon.java#L87

@jamshid
Copy link

jamshid commented Jun 11, 2017

Anyone that ends up here looking to mvn deploy to an S3-compatible server...
Instead of using this aws-maven extension from org.springframework.build, try this patch for the maven-s3-wagon extension jcaddel/maven-s3-wagon#28. Unfortunately you need to build and deploy it somewhere before you can actually use it, but it does work.

@xavs
Copy link

xavs commented Feb 6, 2019

This is happening to me as well, with a user with full s3 access.
Cannot write directory 'snapshots/'

5.0.0.RELEASE

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Development

No branches or pull requests

5 participants