NetBird on Debian Servers¶
We run NetBird on our servers to support secure remote access. This guide briefly covers the steps to get NetBird set up on a fresh Debian server.
- Log in to the NetBird control panel and navigate to Settings, then Setup Keys. Or, use this handy deeplink to take you right there.
- Click on Create Key.
- In the key creation window, configure the settings as follows:
- Name: Set the key name to the hostname of the server you’re adding.
- Make this key reusable: Leave set to no.
- Expires in: 1 Day
- Ephemeral peers: Leave set to no.
- Allow extra DNS labels: Leave set to no.
- Auto-assigned groups: Choose one or more access groups (what?) to automatically assign to the server.
- After you click on Create, you will receive a long alphanumeric setup key. Store this somewhere safe, as you can only see it once.
- Log in to your Debian server via SSH with a sudo-capable account.
- Add the NetBird repository and prerequisites:
sudo apt-get update sudo apt-get install ca-certificates curl gnupg -y curl -sSL https://pkgs.netbird.io/debian/public.key | sudo gpg --dearmor --output /usr/share/keyrings/netbird-archive-keyring.gpg echo 'deb [signed-by=/usr/share/keyrings/netbird-archive-keyring.gpg] https://pkgs.netbird.io/debian stable main' | sudo tee /etc/apt/sources.list.d/netbird.list - Install NetBird:
- Run NetBird with the setup key:
- Return back to the Peers section of the NetBird control panel and make sure your new server appears on the list.
- Return back to the Setup Keys section (deeplink) and delete the (now invalidated) setup key you just used.