aws / aws-codebuild-docker-images

Official AWS CodeBuild repository for managed Docker images http://docs.aws.amazon.com/codebuild/latest/userguide/build-env-ref.html
Other
1.11k stars 971 forks source link

No longer able to use "n 18.16.0" in build using aws/codebuild/amazonlinux2-x86_64-standard:5.0 #682

Closed neueda-randerson closed 9 months ago

neueda-randerson commented 9 months ago

Describe the bug Since the latest release we now get an error with aws/codebuild/amazonlinux2-x86_64-standard:5.0, whereby "n 18.16.0" no longer works

To Reproduce Run the build.

Get this error:

[Container] 2023/11/14 12:35:59.822533 Running command node --version v18.18.2   [Container] 2023/11/14 12:35:59.849093 Running command n 18.16.0 /codebuild/output/tmp/script.sh: line 4: n: command not found

Expected behavior Node should switch to v18.16.0 as previously:

[Container] 2023/11/10 11:23:52.445996 Running command node --version v18.16.0

[Container] 2023/11/10 11:23:52.456745 Running command n 18.16.0 copying : node/18.16.0 installed : v18.16.0 (with npm 9.5.1)

Logs As above

Platform (please complete the following information): amazonlinux2-x86_64-standard:5.0

Additional context Add any other context about the problem here.

joshlang commented 9 months ago

Unable to use n 18 or n 16 or any n command any longer.

It broke randomly without any changes yesterday.

Rerunning a previously succeeded pipeline now fails.

[Container] 2023/11/14 15:25:46.342564 Entering phase BUILD
--
32 | [Container] 2023/11/14 15:25:46.343123 Running command n 18
33 | /codebuild/output/tmp/script.sh: line 4: n: command not found
34 |  
35 | [Container] 2023/11/14 15:25:46.349184 Command did not exit successfully n 18 exit status 127
36 | [Container] 2023/11/14 15:25:46.353527 Phase complete: BUILD State: FAILED
jamieavins commented 9 months ago

We are in the same boat...

`

[Container] 2023/11/14 15:16:10.200455 Running command n 18.16.0 -- 24 | /codebuild/output/tmp/script.sh: line 4: n: command not found 25 |   26 | [Container] 2023/11/14 15:16:10.282668 Command did not exit successfully n 18.16.0 exit status 127 27 | [Container] 2023/11/14 15:16:10.286950 Phase complete: INSTALL State: FAILED

`

jedkass commented 9 months ago

+1

jonnysooter commented 9 months ago

This is an unexpected issue from CodeBuild and we are reverting the change that caused the issue.

jonnysooter commented 9 months ago

Thank you for opening this issue, it is resolved now. Please try running your builds again.

Screenshot 2023-11-14 at 9 24 39 AM

johan-seesaw commented 9 months ago

We had to fix to aws/codebuild/amazonlinux2-x86_64-standard:5.0-23.07.28 for a bit. I'll update it back to default since you've now marked it as fixed.

tgpfeiffer commented 9 months ago

Thanks for taking care of this, @jonnysooter

I am wondering,

jonnysooter commented 9 months ago

We did not publish an image with this defect, so it's not available to use in ECR. The image versions you see listed are safe to use. The 5.0 image is our latest image and is defect free.

kyptov commented 9 months ago

2 days ago my pipelines started to fail. No updates, no issues. It was very strange. I added npm install -g n to solve the issue. Yesterday it started to fail again. Found this issue, reverted all buildspecs.

The question is, where I can view releases or updates?