Skip to content
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

add linux/arm64 build #168

Closed
vielmetti opened this issue Oct 15, 2021 · 9 comments
Closed

add linux/arm64 build #168

vielmetti opened this issue Oct 15, 2021 · 9 comments
Labels
bug Something isn't working

Comments

@vielmetti
Copy link

This issue tracks work to build headscale for arm64 and to test
it on the usual suspects for that platform: Raspberry Pi 3/4
with 64-bit OS, Ampere, Graviton2, and the like.

I think it might be as simple as adding a stanza to the
goreleaser code, at first glance.

@vielmetti
Copy link
Author

For what it's worth, on a Lenovo Yoga C630 (Windows on Arm, WSL1, Ubuntu 20.04) "make" and "make test" work as expected, and the binary produced works at least as well as producing a usage message.

@juanfont
Copy link
Owner

Done!

Will come in 0.10.3

@juanfont
Copy link
Owner

Hey @vielmetti https://github.com/juanfont/headscale/releases/tag/v0.10.3

Can you confirm they work? I don't have any arm64 machine...

@juanfont juanfont reopened this Oct 16, 2021
@vielmetti
Copy link
Author

I'll confirm correct operations as soon as I bring up a network, @juanfont - hopefully as soon as this weekend.

@juanfont juanfont added the enhancement New feature or request label Oct 17, 2021
@juanfont
Copy link
Owner

@vielmetti any update?

@vladvasiliu
Copy link

This doesn't seem to work:

Error initializing: Binary was compiled with 'CGO_ENABLED=0', go-sqlite3 requires cgo to work. This is a stub

Tried this on both 0.10.5. and 0.10.4 on aarch64 (AWS ARM instance).

I'm not particularly familiar with Go, but according to a quich search around go-sqlite3, you may need to compile this with CGO_ENABLED=1: https://chromium.googlesource.com/external/github.com/mattn/go-sqlite3/#arm

@juanfont juanfont added bug Something isn't working and removed enhancement New feature or request labels Oct 20, 2021
@06kellyjac
Copy link

If you're desperate for an aarch64 build of headscale you can try using the nix/nixpkgs build: https://search.nixos.org/packages?channel=unstable&show=headscale&from=0&size=50&sort=relevance&type=packages&query=headscale

It's currently on 0.9.2 so I'll try update it to 0.10.5 (where I might run into this issue)

$ uname -sm
Linux aarch64

$ nix-env -i headscale
installing 'headscale-0.9.2'
these 2 paths will be fetched (4.28 MiB download, 16.90 MiB unpacked):
  /nix/store/qd3g8rk5hx5zkb70idjh6fa12sh6bipg-mailcap-2.1.53
  /nix/store/rik1a4jznllqnz1dn9qx301if2yzjcjf-headscale-0.9.2
copying path '/nix/store/qd3g8rk5hx5zkb70idjh6fa12sh6bipg-mailcap-2.1.53' from 'https://cache.nixos.org'...
copying path '/nix/store/rik1a4jznllqnz1dn9qx301if2yzjcjf-headscale-0.9.2' from 'https://cache.nixos.org'...
building '/nix/store/jw2q8605liww8hwl55ggxb76qcgg2pdp-user-environment.drv'...

$ headscale --help

headscale is an open source implementation of the Tailscale control server

https://github.com/juanfont/headscale

Usage:
  headscale [command]

Available Commands:
  completion  generate the autocompletion script for the specified shell
  help        Help about any command
  namespaces  Manage the namespaces of Headscale
  nodes       Manage the nodes of Headscale
  preauthkeys Handle the preauthkeys in Headscale
  routes      Manage the routes of Headscale
  serve       Launches the headscale server
  version     Print the version.

Flags:
  -h, --help            help for headscale
  -o, --output string   Output format. Empty for human-readable, 'json' or 'json-line'

Use "headscale [command] --help" for more information about a command.

@juanfont
Copy link
Owner

@vladvasiliu
Copy link

This seems to work.

Don't have the time to do extensive testing, but I could create a namespace and start the server, so I guess the SQLite issue is solved.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

4 participants