I'm wanting to run aws configure in a Github Actions Workflow to set up a deployment pipeline. However, in contrast to the docs found here, setting the environment variables does not seem to work.
Example job:
deploy: name: Test AWS cli runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v2
- name: Configure AWS credentials
uses: aws-actions/configure-aws-credentials@v1
with:
aws-access-key-id: ${{ secrets.AWS_ACCESS_KEY_ID }}
aws-secret-access-key: ${{ secrets.AWS_SECRET_ACCESS_KEY }}
aws-region: us-west-2
- name: Copy files to S3 with the AWS CLI
run: |
which aws
aws configure
Results in
EOF when reading a line
AWS Access Key ID [********************]:
##[error]Process completed with exit code 255.
Which, when reproduced locally, is because it prompts for the access key ID from the aws-cli.
Why does it prompt me for it, when, according to the docs for it, it should pick up the environment variable and set it accordingly?
The secrets have been set up inside Github with the correct naming that is referenced to above.