Tailscale Configuration Example: Difference between revisions

From Teltonika Networks Wiki
No edit summary
No edit summary
Line 1: Line 1:
__TOC__
<p style="color:red">The information in this page is updated in accordance with [https://wiki.teltonika-networks.com/view/FW_%26_SDK_Downloads'''00.07.06.3'''] firmware version.</p>
 
==Introduction==
==Introduction==


Line 7: Line 6:


<u><b>Note:</b> Tailscale is additional software that can be installed from the <b>System → Package Manager</b> page.</u>
<u><b>Note:</b> Tailscale is additional software that can be installed from the <b>System → Package Manager</b> page.</u>
<p style="color:red">The Tailscale VPN package is compatible exclusively with RUTX series devices. This is because Tailscale demands a larger amount of flash space, which surpasses the capacity available on our other devices.</p>


==Prerequisites==
==Prerequisites==


<ul>
<ul>
   <li>A RUTOS device (this example will using RUTX12)</li>
   <li>A RUTX series device (this example will using RUTX12)</li>
   <li>An end device to configure devices (PC, Laptop, Tablet, or Smartphone)</li>
   <li>An end device to configure devices (PC, Laptop, Tablet, or Smartphone)</li>
   <li>Activated Tailscale account. You can register <b><span class="plainlinks">[https://login.tailscale.com/login?next_url=%2Fwelcome here]</span></b>.</li>
   <li>Activated Tailscale account. You can register <b><span class="plainlinks">[https://login.tailscale.com/login?next_url=%2Fwelcome here]</span></b>.</li>
Line 27: Line 27:
<ol>
<ol>
   <li>First, let's make the process simple by installing the Tailscale package on our router. To accomplish this, navigate to System -> Package Manager -> Packages.</li>
   <li>First, let's make the process simple by installing the Tailscale package on our router. To accomplish this, navigate to System -> Package Manager -> Packages.</li>
   <li>Here, you can find it easily by typing "Tailscale" in the search bar as portrayed below.[[File:Networking tailscale configuration example rutx12 tailscale configuration 2.png]]</li>
   <li>Here, you can find it easily by typing "Tailscale" in the search bar as portrayed below.[[File:Networking tailscale configuration example end device tailscale configuration v1.png|border|class=tlt-border]]</li>


   <li>Once the package is installed, you can go to "Services" -> "VPN" -> "Tailscale" to access the corresponding window.</li>
   <li>Once the package is installed, you can go to "Services" -> "VPN" -> "Tailscale" to access the corresponding window.</li>


   <li>The setup process is straightforward. Simply choose "Use login URL" (for increased security and you can use the "Authentication Key," but login will still be required) and activate the service by enabling it.[[File:Networking tailscale configuration example rutx12 tailscale configuration 3.png]]</li>
   <li>The setup process is straightforward. Simply choose "Use login URL" (for increased security and you can use the "Authentication Key," but login will still be required) and activate the service by enabling it and pressing button "Save & Apply".[[File:Networking tailscale configuration example end device tailscale configuration v2.png|border|class=tlt-border]]</li>
    
    
   <li>Once enabled, you'll see a login link that will direct you to the Tailscale website. There, you can connect RUTX12 to the account you created before starting. If the link is not visible, try saving the configuration and reloading the page.[[File:Networking tailscale configuration example rutx12 tailscale configuration 4.png]]</li>
   <li>Once enabled, you'll see a login link that will direct you to the Tailscale website. There, you can connect RUTX12 to the account you created before starting. If the link is not visible, try saving the configuration and reloading the page.[[File:Networking tailscale configuration example end device tailscale configuration v3.1.png|border|class=tlt-border]]</li>


   <li>Follow the instructions to connect your device. If everything is successful, you should see a similar success message.[[File:Networking tailscale configuration example rutx12 tailscale configuration 8.png]]</li>
   <li>Follow the instructions to connect your device. If everything is successful, you should see a similar success message.[[File:Networking tailscale configuration example rutx12 tailscale configuration 8.png|border|class=tlt-border]]</li>


   <li>Now, you will be redirected to your admin console and with that, the RUTX12 setup is complete.[[File:Networking tailscale configuration example rutx12 tailscale configuration 7.png]]</li>
   <li>Now, you will be redirected to your admin console and with that, the RUTX12 setup is complete.[[File:Networking tailscale configuration example end device tailscale configuration v4.png|border|class=tlt-border]]</li>
</ol>
</ol>


Line 44: Line 44:


<ol>
<ol>
   <li>Select another end device you intend to use, whether it's a PC, laptop, mobile phone, or any other device. Then, click the "Add device" button.[[File:Networking tailscale configuration example end device tailscale configuration 1.png]]</li>
   <li>Select another end device you intend to use, whether it's a PC, laptop, mobile phone, or any other device. Then, click the "Add device" button.[[File:Networking tailscale configuration example end device tailscale configuration 6.png|border|class=tlt-border]]</li>


   <li>Afterward, choose the specific device you will be using. For this setup, we'll be selecting a Windows laptop.[[File:Networking tailscale configuration example end device tailscale configuration 2.png]]</li>  
   <li>Afterward, choose the specific device you will be using. For this setup, we'll be selecting a Windows laptop.[[File:Networking tailscale configuration example end device tailscale configuration 2.1.png|border|class=tlt-border]]</li>  


   <li>Once the selected software is installed, go to the taskbar and click on the Tailscale icon.</li>
   <li>Once the selected software is installed, go to the taskbar and click on the Tailscale icon.</li>


   <li>You will be redirected to another page where you need to connect this device. Proceed to connect it.[[File:Networking tailscale configuration example rutx12 tailscale configuration 8.png]]</li>
   <li>You will be redirected to another page where you need to connect this device. Proceed to connect it.[[File:Networking tailscale configuration example rutx12 tailscale configuration 8.png|border|class=tlt-border]]</li>


   <li>Now, you will be redirected once again to the admin console, where both devices will be visible.[[File:Networking tailscale configuration example end device tailscale configuration 5.png]]</li>
   <li>Now, you will be redirected once again to the admin console, where both devices will be visible.[[File:Networking tailscale configuration example end device tailscale configuration 5.png]]</li>
Line 62: Line 62:
Both instances should be connected, and the output should resemble the following.
Both instances should be connected, and the output should resemble the following.


[[File:Networking tailscale configuration example test configuration 1.png]]
[[File:Networking tailscale configuration example test configuration 6.png|border|class=tlt-border]]


Now, you can try pinging devices using VPN addresses and even machine names provided by Tailscale. Note that machine names can be changed. If everything is set up correctly, the ping should return results in a similar fashion as shown in the image below.
Now, you can try pinging devices using VPN addresses and even machine names provided by Tailscale. Note that machine names can be changed. If everything is set up correctly, the ping should return results in a similar fashion as shown in the image below.


[[File:Networking tailscale configuration example test configuration 2.png]]
[[File:Networking tailscale configuration example test configuration 4.png|border|class=tlt-border]]
 
[[File:Networking tailscale configuration example test configuration 5.png|border|class=tlt-border]]


==Configuring Tailscale exit node==
==Configuring Tailscale exit node==
Line 74: Line 76:
Next, in the admin panel, you should now see a new sign for "exit node." Proceed to enable routing traffic through RUTX12 by clicking on the three dots at the end of the RUTX12 interface and selecting "Edit route settings.
Next, in the admin panel, you should now see a new sign for "exit node." Proceed to enable routing traffic through RUTX12 by clicking on the three dots at the end of the RUTX12 interface and selecting "Edit route settings.


[[File:Networking tailscale configuration example configuring tailscale exit node 1.png]]
[[File:Networking tailscale configuration example configuring tailscale exit node 4.png.png|border|class=tlt-border]]


Then, activate the "Use as exit node" option.
Then, activate the "Use as exit node" option.


[[File:Networking tailscale configuration example configuring tailscale exit node 2.png]]
[[File:Networking tailscale configuration example configuring tailscale exit node 2.png|border|class=tlt-border]]


After completing these steps, go to the control panel on your laptop. In Tailscale, choose "exit node" -> RUTX12. This should complete the process, and now the traffic from your laptop will pass through the exit node RUTX12, with your laptop's traffic having the IP address of RUTX12.
After completing these steps, go to the control panel on your laptop. In Tailscale, choose "exit node" -> RUTX12. This should complete the process, and now the traffic from your laptop will pass through the exit node RUTX12, with your laptop's traffic having the IP address of RUTX12.
==See also==
* Other types of VPNs suported by RUTX devices:
** [[L2TP configuration examples]]
** [[IPsec configuration examples]]
** [[GRE Tunnel configuration examples]]
** [[OpenVPN configuration examples]]
** [[PPTP configuration examples]]
** [[WireGuard Configuration Example]]
==References==
[https://tailscale.com/ Tailscale] - Main Tailscale website
[https://wiki.teltonika-networks.com/view/RUT900_CLI CLI] - Tutorial how to access CLI via WebUI

Revision as of 12:42, 30 January 2024

The information in this page is updated in accordance with 00.07.06.3 firmware version.

Introduction

Tailscale is a straightforward peer-to-peer VPN service that utilizes the open-source WireGuard protocol. This page provides an example of how to configure Tailscale VPN nodes, including the option to use one of the nodes as an exit node.

Note: Tailscale is additional software that can be installed from the System → Package Manager page.

The Tailscale VPN package is compatible exclusively with RUTX series devices. This is because Tailscale demands a larger amount of flash space, which surpasses the capacity available on our other devices.

Prerequisites

  • A RUTX series device (this example will using RUTX12)
  • An end device to configure devices (PC, Laptop, Tablet, or Smartphone)
  • Activated Tailscale account. You can register here.

End results

In the end, a secure tunnel will be established between RUTX12 and any of your devices. We can also utilize RUTX12 as the endpoint device, serving as the point through which our connection reaches the internet. This means that our device will have the IP address of RUTX12.

Tailscale instances

RUTX12 Tailscale configuration

  1. First, let's make the process simple by installing the Tailscale package on our router. To accomplish this, navigate to System -> Package Manager -> Packages.
  2. Here, you can find it easily by typing "Tailscale" in the search bar as portrayed below.
  3. Once the package is installed, you can go to "Services" -> "VPN" -> "Tailscale" to access the corresponding window.
  4. The setup process is straightforward. Simply choose "Use login URL" (for increased security and you can use the "Authentication Key," but login will still be required) and activate the service by enabling it and pressing button "Save & Apply".
  5. Once enabled, you'll see a login link that will direct you to the Tailscale website. There, you can connect RUTX12 to the account you created before starting. If the link is not visible, try saving the configuration and reloading the page.
  6. Follow the instructions to connect your device. If everything is successful, you should see a similar success message.
  7. Now, you will be redirected to your admin console and with that, the RUTX12 setup is complete.


Another end device configuration configuration

  1. Select another end device you intend to use, whether it's a PC, laptop, mobile phone, or any other device. Then, click the "Add device" button.
  2. Afterward, choose the specific device you will be using. For this setup, we'll be selecting a Windows laptop.
  3. Once the selected software is installed, go to the taskbar and click on the Tailscale icon.
  4. You will be redirected to another page where you need to connect this device. Proceed to connect it.
  5. Now, you will be redirected once again to the admin console, where both devices will be visible.

Testing configuration

To test connection you need to open Command Line Interface on RUTX12 (Services → CLI) and login. Then type:

   tailscale status

Both instances should be connected, and the output should resemble the following.

Now, you can try pinging devices using VPN addresses and even machine names provided by Tailscale. Note that machine names can be changed. If everything is set up correctly, the ping should return results in a similar fashion as shown in the image below.

Configuring Tailscale exit node

To begin, we must allow traffic to be routed through RUTX12. Execute the following command in RUTX12 CLI:

   tailscale set --advertise-exit-node

Next, in the admin panel, you should now see a new sign for "exit node." Proceed to enable routing traffic through RUTX12 by clicking on the three dots at the end of the RUTX12 interface and selecting "Edit route settings.

Then, activate the "Use as exit node" option.

After completing these steps, go to the control panel on your laptop. In Tailscale, choose "exit node" -> RUTX12. This should complete the process, and now the traffic from your laptop will pass through the exit node RUTX12, with your laptop's traffic having the IP address of RUTX12.

See also

References

Tailscale - Main Tailscale website

CLI - Tutorial how to access CLI via WebUI