Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

GitHub Action No Longer Works Due to Deprecation of Add-Path #41

Closed
LuisOsta opened this issue Nov 17, 2020 · 3 comments
Closed

GitHub Action No Longer Works Due to Deprecation of Add-Path #41

LuisOsta opened this issue Nov 17, 2020 · 3 comments

Comments

@LuisOsta
Copy link

LuisOsta commented Nov 17, 2020

Recently GitHub actions deprecated the usage of set-env and add-path commands due to security vulnerabilities.
You can find more about that here: https://github.blog/changelog/2020-10-01-github-actions-deprecating-set-env-and-add-path-commands/

So currently I can't use the Doctl GitHub action. While there is a short-term solution to allow insecure commands, since I can't do that on an action-specific basis I don't really think that's a viable route.

Here's a screen capture of the error message:
image

How difficult would it be to fix this for the doctl github action?

@andrewsomething
Copy link
Member

From https://github.blog/changelog/2020-10-01-github-actions-deprecating-set-env-and-add-path-commands/

Action authors who are using the toolkit should update the @actions/core package to v1.2.6 or greater to get the updated addPath and exportVariable functions.

We updated to v1.2.6 in: #35 This was part of the v2.1.0 release: https://github.com/digitalocean/action-doctl/releases/tag/v2.1.0

How are you specifying the version of action-doctl in yor workflow? If you point at the v2 branch, this should work:

    - name: Install doctl
      uses: digitalocean/action-doctl@v2
      with:
        token: ${{ secrets.DIGITALOCEAN_ACCESS_TOKEN }}

If you are using a specific version tag, you will need to update to v2.1.0:

uses: digitalocean/action-doctl@v2.1.0

@LuisOsta
Copy link
Author

You're completely right! I had hard-coded the version to 2.0.0. Thanks!

@andrewsomething
Copy link
Member

👍 No problem! Glad to hear it's working.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants