Commit graph

136 commits

Author SHA1 Message Date
Percy Wegmann
3a217367ca validate that when using an OAuth client, tags are specified
Also include a troubleshooting section in the README with information about the
requested tags are invalid or not permitted error.

Updates #78

Signed-off-by: Percy Wegmann <percy@tailscale.com>
2025-10-20 14:38:46 -05:00
Mario Minardi
1293ebc018 .github: add dependabot config
Add basic dependabot config to check for actions / npm updates daily.
This mirrors the config we currently have in the terraform provider repo
but with go swapped for npm.

Fixes https://github.com/tailscale/github-action/issues/207

Signed-off-by: Mario Minardi <mario@tailscale.com>
2025-10-20 14:18:35 -05:00
Percy Wegmann
2ddbe90864 stop tailscale service after CI workload finishes
Updates #205

Signed-off-by: Percy Wegmann <percy@tailscale.com>
2025-10-20 12:53:03 -05:00
Percy Wegmann
aa604318b6 run all commands silently
To avoid leaking any potentially sensitive information, all commands are now run
without logging to the console. Logging can be enabled by turning on debug logging
as described at https://docs.github.com/en/actions/how-tos/monitor-workflows/enable-debug-logging.

Updates tailscale/corp#33405

Signed-off-by: Percy Wegmann <percy@tailscale.com>
2025-10-15 14:31:02 -05:00
Lee Briggs
b69384a992
Merge pull request #203 from tailscale/secrets
use `setSecret` to mask secrets from logs
2025-10-15 15:03:34 -04:00
Lee Briggs
0edb496506
mask secrets
Signed-off-by: Lee Briggs <lee@leebriggs.co.uk>
2025-10-15 14:59:05 -04:00
Percy Wegmann
ac425ca194 stop echoing tailscale status to console
Updates #201

Signed-off-by: Percy Wegmann <percy@tailscale.com>
2025-10-14 16:46:07 -05:00
Percy Wegmann
2976a889fc miscellaneous cleanup items from upgrading to TypeScript action
Updates tailscale/corp#32821

Signed-off-by: Percy Wegmann <percy@tailscale.com>
2025-10-14 13:12:31 -05:00
Percy Wegmann
2c45c8a0fd configure DNS on macOS runners
On macOS, `tailscaled` does not manage DNS. Configure it manually in the GitHub action to make
sure MagicDNS name resolution works.

Updates tailscale/corp#32821

Signed-off-by: Percy Wegmann <percy@tailscale.com>
2025-10-14 13:12:31 -05:00
Percy Wegmann
d4729ea54c miscellaneous cleanup items from upgrading to TypeScript action
Updates tailscale/corp#32821

Signed-off-by: Percy Wegmann <percy@tailscale.com>
2025-10-14 13:12:31 -05:00
Percy Wegmann
392b48279b fix bugs in ping logic, ping hosts in parallel, and tweak README and LICENSE
The ping logic had some bugs in the wait logic which are now fixed.

Pinging hosts in parallel will speed up CI.

LICENSE and README got small updates in preparation for moving this code
to tailscale/github-action.

Updates tailscale/corp#32862

Signed-off-by: Percy Wegmann <percy@tailscale.com>
2025-10-14 13:12:31 -05:00
Percy Wegmann
d2d502c92b update documentation and LICENSE to match existing github-action and document new features
Documented new features:

- Logout functionality
- Ping functionality

Also removed speed-comparison CI flow in preparation for replacing the official GitHub
action with this one.

Updates tailscale/corp#32820

Signed-off-by: Percy Wegmann <percy@tailscale.com>
2025-10-14 13:12:31 -05:00
Percy Wegmann
cff51cdb0c stop pinging hosts as soon as any connectivity is available
Even if we just have DERP connectivity, stop pinging so that action can continue sooner.

Updates tailscale/corp#32862

Signed-off-by: Percy Wegmann <percy@tailscale.com>
2025-10-14 13:12:31 -05:00
Percy Wegmann
fc77efa75d adjust action parameters based on original tailscale/github-action
`oauth-client-secret` is renamed to `oauth-secret` to match the original action.

Not all of the descriptions matched exactly, but this attempts to take the best from both versions.

Default Tailscale version is updated to 1.88.3.

Updates tailscale/corp#32814

Signed-off-by: Percy Wegmann <percy@tailscale.com>
2025-10-14 13:12:31 -05:00
Percy Wegmann
75aaac9f12 add support for testing peer connectivity
The new argument `ping` allows users to specify a comma-seperated list
of hosts (IP or hostname) to ping in order to verify connectivity.
Ping is considered successful as soon as the peer is reachable either
directly or via DERP.

Updates tailscale/corp#32817

Signed-off-by: Percy Wegmann <percy@tailscale.com>
2025-10-14 13:12:31 -05:00
Percy Wegmann
90629cdeb4 factor out commonly repeated constants
Updates tailscale/corp#31655

Signed-off-by: Percy Wegmann <percy@tailscale.com>
2025-10-14 13:12:31 -05:00
Percy Wegmann
cf94bd9cf6 support "unstable" version option on all platforms except macOS
The tailscale repo does not get tagged for unstable builds, so the best we can do when
building macOS from source is to build from the HEAD of `main`.

Updates tailscale/corp#32813

Signed-off-by: Percy Wegmann <percy@tailscale.com>
2025-10-14 13:12:31 -05:00
Percy Wegmann
660d7be521 CI: check that code has been formatted and dist built
Updates tailscale/corp#32815

Signed-off-by: Percy Wegmann <percy@tailscale.com>
2025-10-14 13:12:31 -05:00
Percy Wegmann
39ac0a5882 add dependency on prettier and apply autoformatting
Updates tailscale/corp#30483

Signed-off-by: Percy Wegmann <percy@tailscale.com>
2025-10-14 13:12:31 -05:00
Percy Wegmann
391d5e0792 get tests running in new repo
- Use secrets from the new repo
- Build MacOS from source

Updates tailscale/corp#31655

Signed-off-by: Percy Wegmann <percy@tailscale.com>
2025-10-14 13:12:31 -05:00
Lee Briggs
ed8cd4e9bf check status
Signed-off-by: Lee Briggs <lee@leebriggs.co.uk>
Signed-off-by: Percy Wegmann <percy@tailscale.com>
2025-10-14 13:12:31 -05:00
Lee Briggs
b9a346ef11 change name
Signed-off-by: Lee Briggs <lee@leebriggs.co.uk>
Signed-off-by: Percy Wegmann <percy@tailscale.com>
2025-10-14 13:12:31 -05:00
Lee Briggs
992dc80701 move speed test into its own workflow
Signed-off-by: Lee Briggs <lee@leebriggs.co.uk>
Signed-off-by: Percy Wegmann <percy@tailscale.com>
2025-10-14 13:12:31 -05:00
Lee Briggs
ea786a8afe update performance claims
Signed-off-by: Lee Briggs <lee@leebriggs.co.uk>
Signed-off-by: Percy Wegmann <percy@tailscale.com>
2025-10-14 13:12:31 -05:00
Lee Briggs
ece0596be3 initial commit
Signed-off-by: Lee Briggs <lee@leebriggs.co.uk>
Signed-off-by: Percy Wegmann <percy@tailscale.com>
2025-10-14 13:12:31 -05:00
Percy Wegmann
540ac650e6 delete original implementation of GitHub action
This is in preparation for cherry-picking the new typescript implementation from
https://github.com/tailscale/action-setup-tailscale.

Updates tailscale/corp#32821

Signed-off-by: Percy Wegmann <percy@tailscale.com>
2025-10-14 13:12:31 -05:00
Percy Wegmann
7bdbdbb519 action.yml: bump tailscale version to 1.88.3
Signed-off-by: Percy Wegmann <percy@tailscale.com>
2025-09-29 14:09:53 -05:00
Mario Minardi
1db1f8e300
Merge pull request #197 from tailscale/mpminardi/document-unstable
README.md: document ability to specify unstable for version
2025-09-25 09:58:49 -06:00
Mario Minardi
a8723264f7
README.md: document ability to specify unstable for version
Doucment that "unstable" is now a valid input for version.

Updates #cleanup

Signed-off-by: Mario Minardi <mario@tailscale.com>
2025-09-25 09:55:07 -06:00
Max Coulombe
6cae46e2d7
Merge pull request #195 from tailscale/max/test-target-connectivity-check
Added argument to test targets connectivity
2025-09-25 11:43:46 -04:00
Max Coulombe
2208a5a58b
Update action.yml
Co-authored-by: Mario Minardi <mario@tailscale.com>
2025-09-25 11:40:17 -04:00
mcoulombe
3eef1cc07c + added argument to test target connectivity
Update action.yml

Co-authored-by: Mario Minardi <mario@tailscale.com>
2025-09-25 10:25:14 -04:00
Max Coulombe
0263d9e6d7
Merge pull request #196 from tailscale/max/sanitize-hostnames
action: auto-sanitize default or error on invalid user-defined hostname
2025-09-23 15:36:50 -04:00
mcoulombe
dc4930bf38 action: auto-sanitize default or error on invalid user-defined hostname
Fixes #192
2025-09-23 15:02:42 -04:00
Mario Minardi
6d2f2497d7
Merge pull request #189 from zchee/version-unstable
Support `unstable` version alias
2025-09-12 08:47:56 -06:00
Koichi Shiraishi
59c4d74575
Fix inputs.version.description
Signed-off-by: Koichi Shiraishi <zchee.io@gmail.com>
2025-08-24 01:30:24 +09:00
Koichi Shiraishi
c7fc043ee0
Support unstable version alias
Signed-off-by: Koichi Shiraishi <zchee.io@gmail.com>
2025-08-24 01:13:42 +09:00
Mario Minardi
fd5642846a
Merge pull request #183 from tailscale/mpminardi/granular-scope-testing
.github/workflows: add tests for new / granular minimal OAuth scopes
2025-07-21 10:07:29 -06:00
Mario Minardi
c66619accf
.github/workflows: add tests for new / granular minimal OAuth scopes
Change the default matrix test to use an OAuth client which has the new
set of more granular minimal OAuth scopes necessary to successfully use
the action.

Add a new job that uses the previous OAuth client to ensure that we
don't break legacy clients.

Fixes https://github.com/tailscale/github-action/issues/184

Signed-off-by: Mario Minardi <mario@tailscale.com>
2025-07-04 12:27:49 -06:00
Mario Minardi
84a3f23bb4
Merge pull request #181 from tailscale/mpminardi/windows-unattended-mode
{.github/workflows,action.yml}: run windows in unattended mode
2025-06-26 09:36:38 -06:00
Mario Minardi
8fe6f78f60
{.github/workflows,action.yml}: run windows in unattended mode
Add the `--unattended` flag when running the action on windows-based
machines. This allows the action to properly connect on windows machines
that do not have full GUI support under the hood (e.g., for the current
batch of `windows-11-arm` runners).

Fixes https://github.com/tailscale/github-action/issues/180

Signed-off-by: Mario Minardi <mario@tailscale.com>
2025-06-23 10:07:15 -06:00
Max Coulombe
6986d2c82a
Merge pull request #178 from tailscale/max/add-retry
action: add retry on tailscale up to make the action more reliable
2025-05-23 17:47:38 -04:00
mcoulombe
029c99af76 action: add retry on tailscale up to make the action more reliable
Updates #177
Signed-off-by: mcoulombe <max@tailscale.com>

Co-authored-by: andrea-armstrong

* make retries configurable

* switch to c-style for loop
2025-05-23 17:42:50 -04:00
Mario Minardi
5d536117a7 action.yml: properly remove temporary files after downloading
Remove `.tgz` and `.msi` files after they have been downloaded. This was
the behaviour of the action previous to `v3.2.0`, but our logic for
caching removed the deletion of these files.

Can look at downloading these to temp folders to avoid the more complex
logic here as a follow up, but this should unblock / fix the immediate
regression.

Also, on Windows, write `tailscale.log` to the temp dir.

Also, on MacOS, delete the `tailscale` directory that was used to build the `tailscale(d)` commands.

Updates: #170

Co-authored-by: Mario Minardi <mario@tailscale.com>
Signed-off-by: Percy Wegmann <percy@tailscale.com>
2025-04-09 16:17:15 -05:00
Mario Minardi
9a0fda8cbb
Merge pull request #169 from tailscale/mpminardi/document-use-cache
README.md: document the `use-cache` input
2025-04-09 10:51:29 -06:00
Mario Minardi
91154e3930
README.md: document the use-cache input
Document the `use-cache` input added in https://github.com/tailscale/github-action/pull/166

Updates: https://github.com/tailscale/github-action/issues/87

Signed-off-by: Mario Minardi <mario@tailscale.com>
2025-04-09 10:48:25 -06:00
Mario Minardi
32856f8a74
Merge pull request #166 from palindrom615/main
Cache tailscale binary file
2025-04-09 10:47:19 -06:00
Whoemoon Jang
7af7df6221
Update Download Tailscale - Windows step not to remove tailscale.msi after installation
Co-authored-by: Mario Minardi <mminardi@shaw.ca>
2025-04-07 09:06:23 +09:00
twelsh-aw
4c25f5bef4 feat: Add optional caching to skip repeated Tailscale downloads and builds
This commit introduces a new `use-cache` input to the Tailscale GitHub Action. When set to `true`, the action will attempt to restore/install Tailscale binaries from a GitHub Actions cache, rather than always downloading or rebuilding them. If the cache is a hit, the download/build steps are
skipped, reducing network flakes and speeding up workflows. The default `false` preserves the
original behavior, ensuring full backward compatibility.
2025-04-05 10:16:16 +09:00
jang whoemoon
d954cb8727 Check sha256 checksum for cache 2025-04-03 14:01:19 +09:00