Code Monkey home page Code Monkey logo

Comments (9)

jeffnappi avatar jeffnappi commented on July 29, 2024 1

from aws-ecr-orb.

sparta-developers avatar sparta-developers commented on July 29, 2024 1

@eddiewebb We actually experimented with this and we can in fact pass --profile. The command is not specific to ECR get-login, but rather is picked up by the AWS CLI: https://docs.aws.amazon.com/cli/latest/reference/index.html#cli-aws

For clarity, we invoked the ECR get-login command from the build and push image step referenced here: https://github.com/CircleCI-Public/aws-ecr-orb/blob/master/src/commands/ecr-login.yml#L16
aws ecr get-login --no-include-email --profile our_profile

Let us know if you would like us to open up a PR.

from aws-ecr-orb.

iynere avatar iynere commented on July 29, 2024

thanks ! @jeffnappi i don't think we're currently integration-testing the orb with alternate profile names, let me set that up & that should help resolve this

from aws-ecr-orb.

iynere avatar iynere commented on July 29, 2024

@jeffnappi can you be more specific about where the failure occurs ? feel free to link me to a job, so i can take a look

if the failure is towards the beginning, the bug may be in our AWS CLI orb, not this one—otherwise, if it occurs later on, it's probably an issue with this orb

from aws-ecr-orb.

iynere avatar iynere commented on July 29, 2024

hmmmm, i'm not able to reproduce @jeffnappi https://circleci.com/gh/CircleCI-Public/aws-ecr-orb/224

from aws-ecr-orb.

hollyhutson avatar hollyhutson commented on July 29, 2024

@iynere we saw the same issue where failure occurs if profile-name is set. This occurs when trying to authenticate with ecr using get-login, I believe because the profile isn't set during this step.
I believe the issue is during this: LOGIN_COMMAND=$(aws ecr get-login --no-include-email --region $AWS_REGION)

from aws-ecr-orb.

eddiewebb avatar eddiewebb commented on July 29, 2024

@hollyhutson - thanks for the additional info, but the ECR login command uses this AWS command which does not support profiles - https://docs.aws.amazon.com/cli/latest/reference/ecr/get-login.html

Profile is specified at the time AWS CLI is configured by the underlying AWS orb. https://github.com/CircleCI-Public/aws-ecr-orb/blob/master/src/commands/build-and-push-image.yml#L127

@jeffnappi / @hollyhutson - please include a sample config that sees this issue for us to diagnose further. I'll mark this issue needing more details.

from aws-ecr-orb.

eddiewebb avatar eddiewebb commented on July 29, 2024

Thank you @sparta-developers - that makes good sense.

we would love a PR, I see 2 paths, though you ,might see others

  1. add profile as specific parameter. This follows an established convention and addresses immediate need.
  2. add a generic arguments to the command that could include --profule or other things.

#2 is more future proof but deviates from known patten, so #1 still feels like a good path.

from aws-ecr-orb.

lokst avatar lokst commented on July 29, 2024

@sparta-developers Thank you for your contribution on this issue! We have just released circleci/[email protected] based on your PR and hence will be closing this issue, and would encourage anyone who was following this issue to try out the new version!

from aws-ecr-orb.

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.