actions icon indicating copy to clipboard operation
actions copied to clipboard

change cli node version to latse

Open jonDemoStack opened this issue 4 years ago • 4 comments

can't build and deploy when using CLI please. update to docker node lasts

jonDemoStack avatar May 19 '21 19:05 jonDemoStack

Also having a similar issue, which is breaking my CI. See error below.

Build container for action use: '/home/runner/work/_actions/netlify/actions/master/cli/Dockerfile'.
  /usr/bin/docker build -t 8a33c1:699be542db824dd58ab8c5201e27d463 -f "/home/runner/work/_actions/netlify/actions/master/cli/Dockerfile" "/home/runner/work/_actions/netlify/actions/master/cli"
  Sending build context to Docker daemon   5.12kB
  
  Step 1/12 : FROM node:12-alpine
   ---> deeae3752431
  Step 2/12 : LABEL version="1.0.1"
   ---> Running in aac6aa1c1daa
  Removing intermediate container aac6aa1c1daa
   ---> 4856d00e1f86
  Step 3/12 : LABEL repository="http://github.com/netlify/actions"
   ---> Running in 57487e00418d
  Removing intermediate container 57487e00418d
   ---> c97f04cd9d67
  Step 4/12 : LABEL homepage="http://github.com/netlify/actions/netlify"
   ---> Running in cba7ab060a2f
  Removing intermediate container cba7ab060a2f
   ---> 6db677bf7c66
  Step 5/12 : LABEL maintainer="Netlify"
   ---> Running in 51c9a90eb112
  Removing intermediate container 51c9a90eb112
   ---> e23fec546f2f
  Step 6/12 : LABEL "com.github.actions.name"="Netlify"
   ---> Running in e42fcd825e15
  Removing intermediate container e42fcd825e15
   ---> 9663419b2aed
  Step 7/12 : LABEL "com.github.actions.description"="Wraps the Netlify CLI to enable common Netlify commands"
   ---> Running in 3c6971b9ff62
  Removing intermediate container 3c6971b9ff62
   ---> 8a8e484515b5
  Step 8/12 : LABEL "com.github.actions.icon"="cloud"
   ---> Running in 130287615fb0
  Removing intermediate container 130287615fb0
   ---> b745e1025560
  Step 9/12 : LABEL "com.github.actions.color"="blue"
   ---> Running in 3e9b546c86ac
  Removing intermediate container 3e9b546c86ac
   ---> 593173d979c1
  Step 10/12 : RUN yarn global add netlify-cli
   ---> Running in c042433f3d1f
  yarn global v1.22.5
  [1/4] Resolving packages...
  warning netlify-cli > @netlify/plugin-edge-handlers > rollup-plugin-node-polyfills > [email protected]: This package has been deprecated and is no longer maintained. Please use @rollup/plugin-inject.
  warning netlify-cli > copy-template-dir > readdirp > micromatch > snapdragon > source-map-resolve > [email protected]: Please see https://github.com/lydell/urix#deprecated
  warning netlify-cli > copy-template-dir > readdirp > micromatch > snapdragon > source-map-resolve > [email protected]: https://github.com/lydell/resolve-url#deprecated
  [2/4] Fetching packages...
  info @netlify/[email protected]: The platform "linux" is incompatible with this module.
  info "@netlify/[email protected]" is an optional dependency and failed compatibility check. Excluding it from installation.
  info @netlify/[email protected]: The platform "linux" is incompatible with this module.
  info "@netlify/[email protected]" is an optional dependency and failed compatibility check. Excluding it from installation.
  error @netlify/[email protected]: The engine "node" is incompatible with this module. Expected version ">=15.0.0". Got "12.22.1"
  error Found incompatible module.
  info Visit https://yarnpkg.com/en/docs/cli/global for documentation about this command.
  The command '/bin/sh -c yarn global add netlify-cli' returned a non-zero code: 1

The Dockerfile for the CLI action uses node:12-alpine, but @netlify/eslint-config-node requires at least Node 15. In the most recent release today, it even requires Node 16. This is causing all builds of netlify/actions/cli to fail, which makes the action unusable.

ekzhang avatar May 20 '21 15:05 ekzhang

@kitop Is this repository still being maintained? Right now it does not build at all due to this issue. Perhaps it could be archived / marked as read-only to make sure that people don't unnecessarily spend time trying to use it.

For other people with a similar use case of deploying to Netlify, I was able to find unofficial extensions like South-Paw/action-netlify-deploy that work perfectly.

ekzhang avatar May 26 '21 00:05 ekzhang

Unfortunately all the other github actions seem to use an old version of the netlify js client, since recent versions have removed the ability to deploy to netlify. They've forced us to use the cli, which requires a docker action similar to this one, and so far I haven't found any unofficial actions which do.

IanVS avatar Nov 16 '21 15:11 IanVS

@IanVS https://github.com/South-Paw/action-netlify-cli

This action is a replacement for netlify/actions/cli@master without the docker layer that incurs an extra 30-50s of runner time (which seems result in an average deploy time of ~1m 30s) and so the action usually completes in under a minute (and in best cases, 30s).

South-Paw avatar Dec 20 '22 23:12 South-Paw