Back

Explore Courses Blog Tutorials Interview Questions
0 votes
2 views
in AWS by (7k points)
edited by

We are building our project and have to use AWS CLI v2 to deploy our project. The runtime version is:

phases:
  install:
    runtime-versions:
      nodejs: 12.x

Is an official AWS CodeBuild nodejs image available which we can use and has AWS CLI v2 installed or do we need to create our own? Is there a way to upgrade to v2 for the above runtime? This seems that it works but it might not be very stable in the future:

 # uninstall awscli version 1
 - pip3 uninstall -y awscli
 # install awscli version 2
 - curl "https://awscli.amazonaws.com/awscli-exe-linux-x86_64.zip" -o "awscliv2.zip"
 - unzip awscliv2.zip
 - ./aws/install

1 Answer

0 votes
by (31.9k points)

Official CB docker images are listed here.

The images are also open sourced and we can inspect their Dockerfile files. In both of them, awscli is installed in a similar way:

pip3 install --no-cache-dir --upgrade setuptools wheel aws-sam-cli awscli boto3 pipenv virtualenv

Instructions for installing awscliv2 are different and they do not involve pip.

Are you interested to learn AWS ? Then check out AWS Certification Training Course.

Related questions

Want to get 50% Hike on your Salary?

Learn how we helped 50,000+ professionals like you !

0 votes
1 answer
0 votes
1 answer
0 votes
1 answer
asked Jan 4, 2021 in AWS by Justin (7k points)

Browse Categories

...