Recent update to Code Deploy now breaking build (we made no changes)

0

So we are provisioning a new server for a new project to production, and two days ago we got everything working in production. We have not configured any scripts that cover actual code execution while building our project, but we did add our build script that covers getting a few environment installations in place (update the server, and install a package called yarn)

We have not made any adjustments to the build server yet, because we are not ready for it, but today when rolling out a new update our build server suddenly is crashing on a BASIC task of apt-get update -y

this makes absolutely NO sense from a developer stance, something has had to be done on the AWS side to cause this crash.

I have attached the full logs and our super basic buildspec.yml file of our build

Image
aws/codebuild/standard:4.0

Environment type
Linux

Compute
3 GB memory, 2 vCPUs

Privileged
False

Service role
(not relevant)

Timeout
1 hour 0 minutes

asked 3 years ago718 views
2 Answers
0

After further studying of how apt-get update is crashing on the AWS provided container for Nodejs, I saw that a key is expired for yarn

I contacted the package maintainer and he responded with the following:

Try refreshing your GPG key:
curl -sS https://dl.yarnpkg.com/debian/pubkey.gpg | sudo apt-key add -

so for anyone using the Nodejs container image, please make that your first script before running apt-get update

answered 3 years ago
0

I found this solution did not work. The use of 'sudo' in that context produced the error "sudo not found". Without the 'sudo' it worked.
My BuildProject is created via CloudFormation with the following Environment parameters:
"Environment": {
"ComputeType": "BUILD_GENERAL1_SMALL",
"Image": "aws/codebuild/standard:2.0",
"ImagePullCredentialsType": "CODEBUILD",
"Type": "LINUX_CONTAINER"
}

To use the solution posted here I needed to remove the 'sudo' and run the command like this:
curl -sS https://dl.yarnpkg.com/debian/pubkey.gpg | apt-key add -

Coach Spoon

answered 3 years ago

You are not logged in. Log in to post an answer.

A good answer clearly answers the question and provides constructive feedback and encourages professional growth in the question asker.

Guidelines for Answering Questions