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

set-env and add-path are now disabled for security reasons #99

Open
ggrossetie opened this issue Nov 20, 2020 · 3 comments
Open

set-env and add-path are now disabled for security reasons #99

ggrossetie opened this issue Nov 20, 2020 · 3 comments

Comments

@ggrossetie
Copy link

Using the latest version published (v6), I get the following errors:

Error: Unable to process command '::set-env name=PYENV_ROOT::/opt/hostedtoolcache/pyenv_root/1.2.18/x64' successfully.
Error: The `set-env` command is disabled. Please upgrade to using Environment Files or opt into unsecure command execution by setting the `ACTIONS_ALLOW_UNSECURE_COMMANDS` environment variable to `true`. For more information see: github.blog/changelog/2020-10-01-github-actions-deprecating-set-env-and-add-path-commands
export PYENV_ROOT="/opt/hostedtoolcache/pyenv_root/1.2.18/x64"
Error: Unable to process command '::add-path::/opt/hostedtoolcache/pyenv_root/1.2.18/x64/bin' successfully.
Error: The `add-path` command is disabled. Please upgrade to using Environment Files or opt into unsecure command execution by setting the `ACTIONS_ALLOW_UNSECURE_COMMANDS` environment variable to `true`. For more information see: github.blog/changelog/2020-10-01-github-actions-deprecating-set-env-and-add-path-commands
Error: Unable to process command '::add-path::/opt/hostedtoolcache/pyenv_root/1.2.18/x64/shims' successfully.
Error: The `add-path` command is disabled. Please upgrade to using Environment Files or opt into unsecure command execution by setting the `ACTIONS_ALLOW_UNSECURE_COMMANDS` environment variable to `true`. For more information see: github.blog/changelog/2020-10-01-github-actions-deprecating-set-env-and-add-path-commands

Is there a workaround, apart from setting ACTIONS_ALLOW_UNSECURE_COMMANDS?

@ggrossetie
Copy link
Author

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.

I can see that we are already using 1.2.6 on master, so this is probably just a matter of releasing a new version.

"@actions/core": "1.2.6",

ggrossetie added a commit to yuzutech/kroki that referenced this issue Nov 20, 2020
rethab added a commit to rethab/pyenv-action that referenced this issue Aug 7, 2021
* v5 is broken, so let's ask people to use v8
@tripleee
Copy link

Are the instructions in https://github.com/marketplace/actions/pyenv-build incomplete still? I get these errors when trying this out for the first time.

@tdonovic
Copy link

Same here. The docs seem to say they are removing the commands too, so not sure if this can even be fixed long term https://github.blog/changelog/2020-10-01-github-actions-deprecating-set-env-and-add-path-commands/

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

3 participants