cloudfoundry / nodejs-buildpack

Cloud Foundry buildpack for Node.js
http://docs.cloudfoundry.org/buildpacks/
Apache License 2.0
169 stars 382 forks source link

Add support for Node.js v14.16.1, v12.22.1 and v10.24.1 April 2021 Security Releases #295

Closed konrad-ohms closed 3 years ago

konrad-ohms commented 3 years ago

Hi, the Node.js project published a security release on April 6th, 2021 to address OpenSSL and y18n issues https://nodejs.org/en/blog/vulnerability/april-2021-security-releases/.

Please add support for the updated Node.js versions v14.16.1, v12.22.1 and v10.24.1 in the buildpack.

Thanks in advance

Problem details

What version of Cloud Foundry and CF CLI are you using? (i.e. What is the output of running cf curl /v2/info && cf version? IBM Cloud

$ ibmcloud cf curl /v2/info 
Invoking 'cf curl /v2/info'...
{
   "name": "IBM Cloud",
   "build": "v16.2.0",
   "support": "http://ibm.biz/bluemix-supportinfo",
   "version": 0,
   "description": "IBM Bluemix",
   "authorization_endpoint": "https://iam.cloud.ibm.com/cloudfoundry/login/us-south",
   "token_endpoint": "https://uaa.us-south.cf.cloud.ibm.com",
   "min_cli_version": null,
   "min_recommended_cli_version": null,
   "app_ssh_endpoint": "xxx",
   "app_ssh_host_key_fingerprint": "xxx",
   "app_ssh_oauth_client": "ssh-proxy",
   "doppler_logging_endpoint": "wss://doppler.us-south.cf.cloud.ibm.com:443",
   "api_version": "2.161.0",
   "osbapi_version": "2.15",
   "user": "xxx"
}

What version of the buildpack you are using? v1.7.47

If you were attempting to accomplish a task, what was it you were attempting to do? I defined the new version of Node.js and npm as part of the package.json of my application:

{
...
  "engines": {
    "node": "14.16.1",
    "npm": "6.14.12"
  },
...
}

Also, I picked up the latest buildpack version in my Cloud Foundry manifest.yaml:

applications:
- name: xxx
  path: "xxx"
  buildpacks:
    - https://github.com/cloudfoundry/nodejs-buildpack.git#v1.7.47
...

What did you expect to happen? I expected to installing Node.js v14.16.1.

What was the actual behavior? An error occurred during the application deployment:

Waiting for API to complete processing files...
Staging app and tracing logs...
   Cell xxx creating container for instance xxx
   Cell xxx successfully created container for instance xxx
   Downloading app package...
   Downloaded app package (68.8M)
   -----> Download go 1.15.5
   -----> Running go build supply
   /tmp/buildpackdownloads/b700ccddebe12eb2f99ce4191db84fd0 ~
   ~
   -----> Nodejs Buildpack version 1.7.47
   -----> Installing binaries
          engines.node (package.json): 14.16.1
          engines.npm (package.json): 6.14.12
          \u001b[31;1m**ERROR**\u001b[0m Unable to install node: no match found for 14.16.1 in [10.23.3 10.24.0 12.21.0 12.22.0 14.15.5 14.16.0 15.12.0 15.13.0]
   Failed to compile droplet: Failed to run all supply scripts: exit status 14
   Exit status 223
   Cell xxx stopping instance xxx
   Cell xxx destroying container for instance xxx
FAILED

Can you provide a sample app? The problem should be application independent.

Please confirm where necessary:

cf-gitbot commented 3 years ago

We have created an issue in Pivotal Tracker to manage this:

https://www.pivotaltracker.com/story/show/177677600

The labels on this github issue will be updated when the story is started.

konrad-ohms commented 3 years ago

Looks like the @cf-buildpacks-eng bot created an issue for the upcoming release: https://github.com/cloudfoundry/nodejs-buildpack/issues/296. Once the release has been published, this issue can be closed as well.

konrad-ohms commented 3 years ago

Thank you very much, I just verified that Node.js v14.16.1 is used after updating the buildpack of my deployment.

$ ibmcloud cf ssh xxx -c "/home/vcap/deps/0/bin/node -v"
Invoking 'cf ssh xxx -c /home/vcap/deps/0/bin/node -v'...

v14.16.1