How to send files with Tailscale on Linux
Tailscale is a self-hosted mesh-VPN tool that users can install to connect their computers behind firewalls. In this guide, we’ll show you how you can utilize the new “send files” feature on Linux to send files with Tailscale.
How to set up Tailscale on Linux
You need to set up Tailscale on your Linux system before you can use it to share files between your Linux systems with it. Thankfully, setting up Tailscale on most Linux systems is easy.
To start, open up a terminal window on the Linux desktop. You can open up a terminal on your Linux desktop by pressing Ctrl + Alt + T on the keyboard. Or, alternatively, you can search for “Terminal” in the app menu and launch it that way.
Once the terminal app is open, all you need to do is execute the Tailscale installation script. However, you should take a look at the contents of the script before running it, as it isn’t advised to run a script without reading its contents.
When you’ve taken a look at the Tailscale installation script, you can install the Tailscale software on your computer using the following command.
Note: you must ensure that the “curl” command is installed on your Linux system before running the command below.
curl -fsSL https://tailscale.com/install.sh | sh
After the command above is run, Tailscale will be installed on your system. However, you need to log into Tailscale so that you can use it on your system. To log in, simply execute the command below in the terminal.
sudo tailscale up --operator=$USER
When you run the command above, a URL will appear in the terminal. Open this URL in a web browser, and log into your account. If you do not have an account, you can create one on the Tailscale website.
How to enable file-sharing in Tailscale
Tailscale’s file-sharing feature isn’t turned on by default. Instead, you need to turn it on manually. Here’s how to do it. First, go to the Tailscale website, and log in. Then, select the button to access your Admin console.
Inside of the Tailscale Admin console, find the “Settings” area, and click on it with the mouse. Once you’ve loaded up the “Settings” area, scroll through and find the “Feature Preview” area.
After accessing the “Feature Preview” area, scroll down locate the “Send Files” option, and click the slider to enable this feature. Please keep in mind that Tailscale’s “Send Files” feature is in Alpha.
When you enable the “Send Files” option in Tailscale, it’ll be turned on for all of your devices on your Tailnet automatically.
Sending files with Tailscale via the terminal
Sending files over Tailscale via the terminal on Linux is quite easy. To start, ensure your Linux PC is connected to the Tailnet. Additionally, ensure the other device (Mac OS, Windows, Android, or iOS) is also connected.
Once both devices are connected to the Tailnet, use the tailscale status
command to confirm that the devices are connected. If everything is working, both devices will be listed in the status printout.
Use the status printout to find the name of the device you’re sending a file to over Tailscale. Then, plug it into the command formula below.
tailscale file cp /location/of/file/on/your/pc/file.txt tailscale-name-or-ip:
When this command is run, the device receiving the file should automatically download the sent file. It’ll place the sent file in the “Downloads” folder. To access your file, simply load up your “Downloads” folder.
Sending files with Tailscale via a GUI
If you do not wish to fuss with the terminal, you can also send files using a GUI on Linux. There are a few GUI tools for Tailscale on Linux. For KDE Plasma users, there is Ktailctl. For Gnome users, there is Trayscale.
Both Ktailctl and Trayscale are available on the Flathub app store. To use either of these applications, ensure that Tailscale is up and running and that you are logged in. Also, ensure that the device you wish to send a file to is connected to the Tailnet.
Ktailctl
To send a file using the Ktailctl app on Linux, do the following. First, find “Peers”
in Ktailctl, and select it. Then, look through your list of peers, and click the “Send file(s)” button.
After selecting the “Send file(s)” button, browse for the file to send it to the other machine on your Tailnet. The file will appear in the “Downloads” directory of the target machine.
Trayscale
Find a Tailscale peer in the Trayscale sidebar, and select it with the mouse. After you’ve selected the peer, find the “Send a file to remote machine” and click it with the mouse.
When you’ve selected the “Send a file to remote machine” button, browse for the file you wish to send, and select it. Once you’ve selected the file, it’ll be sent over the Tailnet to the target’s “Downloads” folder.