ssh-key-action
ssh-key-action copied to clipboard
Error: HOME is not defined
I start my hosted runner and when it gets to the ssh-key-action step, I get the error message in the subject. When I ssh into the runner and executes: echo $HOME, I get /home/ubuntu as expected
What am I missing here?
I've got the same on a self-hosted runner.
My workaround:
- run: mkdir -p /home/runner && chmod -R 777 /home/runner
- run: echo "HOME=/home/runner" >> $GITHUB_ENV
Hi, @gilShin @chekalsky Thank you for your report, and sorry for late response.
I start my hosted runner and when it gets to the ssh-key-action step, I get the error message in the subject.
It looks strange... :thinking: I found issue https://github.com/actions/runner/issues/1864, you might want to read it!
same issue here, self-hosted ubuntu-latest
I've fixed this issue by adding an env to the step
.
- name: Install SSH key
uses: shimataro/ssh-key-action@v2
env:
HOME: /root
with:
.....
I only have this issue on a custom runner, not on the default Ubuntu runners provided by GitHub.