Jump to content

Update of action in deploy.yaml required


gebeer
 Share

Recommended Posts

Hi @bernhard

we just ran into some error with the deployment script:

The following actions use a deprecated Node.js version and will be forced to run on node20: actions/checkout@v3. For more info:

https://github.blog/changelog/2024-03-07-github-actions-all-actions-will-run-on-node20-instead-of-node16-by-default/ 

Seems related to the action in use: uses: actions/checkout@v3

 

Link to comment
Share on other sites

18 minutes ago, bernhard said:

Thx @gebeer I've seen that warning for a long time but didn't find the time to look into it yet. I'm not sure I understand this thread though?! What are you suggesting? Do you have a solution or was this just a report?

I think you need to update to action/checkout@v4. Looking at their changelog https://github.com/actions/checkout/blob/main/CHANGELOG.md they updated to Node 20 in v.4.0.0. That should take care of the problem.

Alternatively, if you, for some reason, must stay on v3, you can set an env var FORCE_JAVASCRIPT_ACTIONS_TO_NODE20=true

But I would try to avoid that because of https://github.blog/changelog/2024-03-07-github-actions-all-actions-will-run-on-node20-instead-of-node16-by-default/#removal-of-operating-system-support-for-non-node20-os-versions

Hope that helps :-)

  • Thanks 1
Link to comment
Share on other sites

Unfortunately it was not as easy as changing the version number. I had to find another workflow as the one used was archived and not maintained any more. But I have now added a dedicated auto-release workflow file to RockMigations which anybody can use to create fully automated releases (without nodejs deprecation notices) 😎

name: Auto-Release

on:
  push:
    branches:
      - main

jobs:
  auto-release:
    uses: baumrock/RockMigrations/.github/workflows/auto-release.yml@main
    secrets:
      token: ${{ secrets.GITHUB_TOKEN }}

 

  • Like 1
Link to comment
Share on other sites

26 minutes ago, bernhard said:

I had to find another workflow as the one used was archived and not maintained any more

The one I had linked to which is the official github checkout action is not deprecated https://github.com/actions/checkout and in active development.

Could you provide the link to the deprecated version?

EDIT: Ah, I see https://github.com/baumrock/RockMigrations/blob/main/.github/workflows/auto-release.yml uses the actions/checkout@v4 :-)

So in our local main.yaml we need to use

jobs:
  deploy-to-production:
    uses: baumrock/RockMigrations/.github/workflows/auto-release.yaml@main // instead of deploy.yaml

Could you please confirm?

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...