Git Product home page Git Product logo

Comments (27)

SebastiaanKlippert avatar SebastiaanKlippert commented on June 20, 2024 4

Too bad this is still an open issue. Is there any news on this?
V4 authentication (http://docs.aws.amazon.com/AmazonS3/latest/API/sig-v4-authenticating-requests.html) is required for all new AWS regions, so this will be an issue for all new regions.
For a German based company I would expect Frankfurt to be supported πŸ˜†

I think the only way to go now is the official AWS Go SDK at https://github.com/aws/aws-sdk-go which supports V4 out of the box and is updated regularly. I have used this is other projects as well and our production servers upload loads to eu-central-1 buckets using this package.

If I have time I can also take a look at this if needed. No idea what your current code is like but I don't think it should be too much work to change packages.

from artifacts.

Deadolus avatar Deadolus commented on June 20, 2024 2

Adding the ARTIFACTS_REGION environment variable did not change anything for me.
Once I changed to a Oregon based bucket, everything worked as expected.

I used the exact same setup for both, once using
ARTIFACTS_REGION set to eu-central-1 and once to us-west-2 (so not default!).
This is the repository I'm talking about: https://github.com/bbvch/street-light-simulator
Although not critical for this project, I would of course like travis to support european buckets.

from artifacts.

BanzaiMan avatar BanzaiMan commented on June 20, 2024 2

Hmmm. It doesn't work just yet. https://travis-ci.org/BanzaiMan/travis_production_test/builds/123420742#L165

ERROR: failed to upload: /home/travis/build/BanzaiMan/travis_production_test/Gemfile
  err: The authorization mechanism you have provided is not supported. Please use AWS4-HMAC-SHA256.

mitchellh/goamz#166

from artifacts.

magthe avatar magthe commented on June 20, 2024 2

Is there any workaround I can use until Travis feels it's a problem that they have support for artifacts: in less than half the AWS S3 regions?

from artifacts.

DenysVuika avatar DenysVuika commented on June 20, 2024 2

I can't believe this issue is still not resolved since 2015, it's almost 2019 out there!

The deploy works fine with eu-west-2 for instance, but artifacts fail with the same infamous error: WARNING: invalid region, defaulting to [secure].

I would gladly use the deploy only, if there's any way to use it when build fails (i.e. uploading test reports to S3).

from artifacts.

Jell avatar Jell commented on June 20, 2024 1

seeing the same issue, getting either:

The bucket you are attempting to access must be addressed using the specified endpoint. Please send all future requests to this endpoint.

or

unsupported protocol scheme ""

from artifacts.

Primajin avatar Primajin commented on June 20, 2024 1

Is there any update on this? I still either get wrong endpoint or use AWS4-HMAC-SHA256 😞

from artifacts.

Myasuka avatar Myasuka commented on June 20, 2024 1

Can't believe this problem still exist in 2023 after the 1st reporting in 2015 :(

from artifacts.

ldonnet avatar ldonnet commented on June 20, 2024

πŸ‘ same problem

from artifacts.

ensonic avatar ensonic commented on June 20, 2024

+1 finally use us-west-1 and it worked.

from artifacts.

cmouse avatar cmouse commented on June 20, 2024

+1 same problem, tried using eu-central-1.

from artifacts.

sjackman avatar sjackman commented on June 20, 2024

The artifacts command line tool works for me with region us-west-2, but Travis CI does not. It appears to ignore the configuration variable addons.s3_region.
Works:

ARTIFACTS_REGION=us-west-2 artifacts upload --key=$redacted --secret=$redacted --bucket=foo bar

Travis CI does not work:

err: The bucket you are attempting to access must be addressed using the specified endpoint. Please send all future requests to this endpoint.

https://travis-ci.org/Linuxbrew/linuxbrew/builds/107042959#L4267
My .travis.yml includes:

addons:
  artifacts:
    debug: true
  s3_region: "us-west-2"

from artifacts.

sjackman avatar sjackman commented on June 20, 2024

A workaround for Travis CI is to set the environment variable ARTIFACTS_REGION rather than the .travis.yml variable addons.s3_region.

from artifacts.

sjackman avatar sjackman commented on June 20, 2024

Just a long shot question, should the .travis.yml variable perhaps be addons.artifacts.s3_region rather than addons.s3_region as the documentation indicates?

from artifacts.

dacoinminster avatar dacoinminster commented on June 20, 2024

I had the same problem, and can confirm that official travis documentation is INCORRECT on this page:

https://docs.travis-ci.com/user/uploading-artifacts/

The first example shows the setting being addons.s3_region, but the setting is actually addons.artifacts.s3_region

My .travis.yml file now has:

- addons:
  - postgresql: '9.3'
  - artifacts:
    - s3_region: "us-west-2" # defaults to "us-east-1"
    - paths:
      - $(ls tmp/capybara/screenshot_* | tr "\n" ":")

Travis: please fix your documentation! Thanks!

from artifacts.

brauliobo avatar brauliobo commented on June 20, 2024

@dacoinminster could you please create a PR to https://github.com/travis-ci/docs-travis-ci-com?

from artifacts.

dacoinminster avatar dacoinminster commented on June 20, 2024

It looks like somebody already did (travis-ci/docs-travis-ci-com#524)

from artifacts.

BanzaiMan avatar BanzaiMan commented on June 20, 2024

Hi, everyone,

Sorry for the delay. I pushed an update which I think might fix this issue. Could you try it again?

from artifacts.

BanzaiMan avatar BanzaiMan commented on June 20, 2024

I think https://github.com/goamz/goamz/ might be a better bet going forward (it supports SHA256 https://github.com/mitchellh/goamz/search?utf8=%E2%9C%93&q=sha256).

I tried my hand at transitioning to it; some tweaks are necessary to source to compile, but I could not get tests to pass. See https://travis-ci.org/travis-ci/artifacts/builds/123291124#L219-L222. I read sources to figure out why the error is happening, but my understanding of Go was not enough to push me over the edge.

from artifacts.

jeschkies avatar jeschkies commented on June 20, 2024

Same here. It seems it's still not fixed. Works fine with a bucket in Ireland.

from artifacts.

iriberri avatar iriberri commented on June 20, 2024

We've received some similar reports for eu-west-2, eu-east-2 and eu-central regions through support.

from artifacts.

BanzaiMan avatar BanzaiMan commented on June 20, 2024

The full list can be seen here: https://docs.aws.amazon.com/general/latest/gr/rande.html#s3_region

The issue is reliance on an old AWS library, https://github.com/mitchellh/goamz.

from artifacts.

Incognito avatar Incognito commented on June 20, 2024

Folks, my team needs this. Can someone at Travis ci please update the aws library?

from artifacts.

ehuelsmann avatar ehuelsmann commented on June 20, 2024

Yup. Running into this too. Maybe I just need to install the aws client and do it all myself?

from artifacts.

ehuelsmann avatar ehuelsmann commented on June 20, 2024

actually, using pip install awscli --user --upgrade and adding the required aws s3 commands is about 100x faster than using this addon (due to the endless tinkering before finding this bug). Please update documentation to say so.

from artifacts.

remal avatar remal commented on June 20, 2024

eu-central-1 region still doesn't work. The upload process fails with The authorization mechanism you have provided is not supported. Please use AWS4-HMAC-SHA256. message.

from artifacts.

Incognito avatar Incognito commented on June 20, 2024

Hey, if the AWS SDK hasn't been updated in nearly 7 years, is that a security issue at this point?

from artifacts.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    πŸ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. πŸ“ŠπŸ“ˆπŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❀️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.