-
Notifications
You must be signed in to change notification settings - Fork 92
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 Failing with Error in Tailscale Setup #137
Comments
I am having the same issue. My secrets are set, but I am getting the message that I need to populate them for my workflow. My secrets are at the organizational level, and these worked when I set them up 2 months ago |
Hey @xLionTamer I got them figured out you can use my template and try it by setting up TS_OAUTH_CLIENT_ID name: Tailscale_deploy
on:
push:
branches:
- main
jobs:
deploy-via-tailscale:
runs-on: ubuntu-latest
steps:
- name: Check out code
uses: actions/checkout@v2
- name: Debug Secrets
run: |
echo "Checking TS_OAUTH_CLIENT_ID"
if [ -z "${{ secrets.TS_OAUTH_CLIENT_ID }}" ]; then
echo "::error::TS_OAUTH_CLIENT_ID is empty"
exit 1
else
echo "TS_OAUTH_CLIENT_ID is set"
fi
echo "Checking TS_OAUTH_SECRET"
if [ -z "${{ secrets.TS_OAUTH_SECRET }}" ]; then
echo "::error::TS_OAUTH_SECRET is empty"
exit 1
else
echo "TS_OAUTH_SECRET is set"
fi
- name: Setup Tailscale
uses: tailscale/github-action@v2
with:
oauth-client-id: ${{ secrets.TS_OAUTH_CLIENT_ID }}
oauth-secret: ${{ secrets.TS_OAUTH_SECRET }}
tags: tag:ci
- name: Verify Tailscale connection
run: |
tailscale ping <NODE IP>
- name: Deploy Application
run: |
echo "Deploying application..."
sshpass -p ${{ secrets.HOSTKEY }} ssh -o StrictHostKeyChecking=no debian@<NODE IP> \
"hostname > /tmp/hostname.txt && echo 'Deployment successful' > /tmp/deploy_status.txt"
|
The fix is, you must use the tag:cli and define it in the ACL sector at the Tailscale admin page. |
The TS_OAUTH_CLIENT_ID and TS_OAUTH_SECRET secrets are confirmed to be set correctly, as indicated by the "Debug Secrets" step.
The error occurs specifically during the "Set up Tailscale" step.
Please provide guidance on resolving this issue or suggest modifications to the workflow to ensure it works correctly.
The text was updated successfully, but these errors were encountered: