Using older versions of Node
arich opened this issue · 0 comments
arich commented
Hi!
I'm supporting a project that still uses Node 8. We use Yarn with it. We plan to upgrade Node to version 12 but we haven't had time to do that yet.
Our CI setup uses your action like this:
eslint:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v1
- name: Use Node.js 8
uses: actions/setup-node@v1
with:
node-version: '8.17.0'
- name: Debug that we actually got node 8.17
run: |
echo $(node --version)
echo $(npm --version)
- uses: stefanoeb/eslint-action@1.0.2
with:
repo-token: ${{secrets.GITHUB_TOKEN}}
I confirmed that after using the actions/setup-node
action, we're using node version 8.17.
Output of the stefanoeb/eslint-action@1.0.2
step:
/usr/bin/docker run --name c1aa2684b8e729a49fcba82cbc58a27ebb6_ab7d7f --label 430c1a --workdir /github/workspace --rm -e INPUT_REPO-TOKEN -e INPUT_FILES -e HOME -e GITHUB_JOB -e GITHUB_REF -e GITHUB_SHA -e GITHUB_REPOSITORY -e GITHUB_REPOSITORY_OWNER -e GITHUB_RUN_ID -e GITHUB_RUN_NUMBER -e GITHUB_ACTOR -e GITHUB_WORKFLOW -e GITHUB_HEAD_REF -e GITHUB_BASE_REF -e GITHUB_EVENT_NAME -e GITHUB_WORKSPACE -e GITHUB_ACTION -e GITHUB_EVENT_PATH -e RUNNER_OS -e RUNNER_TOOL_CACHE -e RUNNER_TEMP -e RUNNER_WORKSPACE -e ACTIONS_RUNTIME_URL -e ACTIONS_RUNTIME_TOKEN -e ACTIONS_CACHE_URL -e GITHUB_ACTIONS=true -e CI=true -v "/var/run/docker.sock":"/var/run/docker.sock" -v "/home/runner/work/_temp/_github_home":"/github/home" -v "/home/runner/work/_temp/_github_workflow":"/github/workflow" -v "/home/runner/work/appname/appname":"/github/workspace" 430c1a:a2684b8e729a49fcba82cbc58a27ebb6 "."
## Your environment is not ready yet. Installing modules...
## Running ESLint
error appname@0.0.1: The engine "node" is incompatible with this module. Expected version "8.17.0". Got "10.14.1"
error appname@0.0.1: The engine "yarn" is incompatible with this module. Expected version ">=1.17.3". Got "1.12.3"
error Found incompatible module
It seems that because your Dockerfile is based off of Node 10, there's a version mismatch when trying to run eslint on our repo.
https://github.com/stefanoeb/eslint-action/blob/master/Dockerfile#L1
Is there a way to get around this? Or is it required that we run the same version of Node as the image used in the Dockerfile?
Thanks!