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

질문됨 3년 전785회 조회
2개 답변
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

답변함 3년 전
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

답변함 3년 전

로그인하지 않았습니다. 로그인해야 답변을 게시할 수 있습니다.

좋은 답변은 질문에 명확하게 답하고 건설적인 피드백을 제공하며 질문자의 전문적인 성장을 장려합니다.

질문 답변하기에 대한 가이드라인

관련 콘텐츠