Skip to content

Commit

Permalink
πŸ› Use IP instead of hostname to connect over SSH
Browse files Browse the repository at this point in the history
  • Loading branch information
kierandrewett committed Apr 27, 2024
1 parent d35d1ab commit 181fbef
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion .github/actions/run-via-ssh/action.yml
Expand Up @@ -44,7 +44,9 @@ runs:
- name: Run script
shell: bash --noprofile --norc -eo pipefail -ux {0}
run: ssh -t ${{ inputs.ssh_username }}@${{ inputs.ts_hostname }} "${{ inputs.run }}"
run: |
SERVER_IP="$(tailscale ip -6 ${{ inputs.ts_hostname }})"
ssh -t ${{ inputs.ssh_username }}@$SERVER_IP "${{ inputs.run }}"
- name: Nuke SSH keys
shell: bash --noprofile --norc -eo pipefail -ux {0}
Expand Down

0 comments on commit 181fbef

Please sign in to comment.