Repository navigation
Conversation
DentonGentry
left a comment
There was a problem hiding this comment.
No, this is not how we're going to do it. We wrote https://github.com/tailscale/tailscale/tree/main/cmd/get-authkey to use in these Actions, and will pass in the client-id+secret from GitHub secrets.
|
@DentonGentry alright, I'm going to close this and people can use this as a workaround until the GH action supports the OAuth Client functionality you just described. |
I started making a PR that uses ( #!/bin/sh
# Need both client id and secret to get auth key, but if one is set, run get-authkey
# and allow it print the error message that both need to be set.
if [[ ! -z "${TS_API_CLIENT_ID}" ]] || [[ ! -z "${TS_API_CLIENT_SECRET}" ]]; then
echo >&2 "TS_API_CLIENT_* environment variables set, attempting to retrieve authkey..."
/usr/local/bin/get-authkey --tags "${TS_API_CLIENT_TAGS}" > /tmp/authkey || exit 1
fi
export TS_API_KEY=$(cat /tmp/authkey)
exec /usr/local/bin/gitops-pusher $*But then it dawned on me... How can Unless you mean we should use the same OAuth flow in |
|
Ah. For an actual API key I think curl is probably fine, it is the two step process to get an authkey where we didn't want to have such a large block of shell code doing it. I think the ideal would be:
|
What
Why
Notes
Closes #19