Skip to content

BrianG61UK/ubnt_get_wireguard

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

41 Commits
 
 
 
 
 
 
 
 

Repository files navigation

Download and install WireGuard on Ubiquiti edge devices

Warning: This script attempts to preserve your running configuration, however you should have a backup of your configuration before running this script.

This script will reference WireGuard/wireguard-vyatta-ubnt repo for WireGuard releases. It will download, install, and setup the package to install post firmware upgrade. Rebooting the device is not required after running this script as long as the script did not generate any errors. Grab the script by running the following commands from the web CLI or SSH.

cd /config/scripts
curl -LO --silent https://github.com/BrianG61UK/ubnt_get_wireguard/raw/UseMe/get_wireguard.sh
chmod +x get_wireguard.sh

Note: Best practice is to save scripts into /config/scripts directory.

Usage

To download and install the latest release of WireGuard, run the following command.

./get_wireguard.sh

To download and install a specific release of WireGuard, run the following command with the desired release as a parameter.

./get_wireguard.sh 1.0.20211208-1

It works for pre-release versions as well if you want to test them before release.

Log

The script writes a log to /tmp/get_wireguard.log. This log file will be removed after reboot of the device.

Automation

To automatically run this script once per week, you can run the following commands from an EdgeMAX device.

configure
set system task-scheduler task get_wireguard executable path /config/scripts/get_wireguard.sh
set system task-scheduler task get_wireguard interval 7d
commit
save
exit

Uninstall

To uninstall WireGuard, run the following command.

sg vyattacfg "$(curl -sL https://github.com/BrianG61UK/ubnt_get_wireguard/raw/UseMe/uninstall_wireguard.sh)"

Alternatively, this fork of whiskerz007 original script has been modified by me so that if you store uninstall_wireguard.sh on your router you can uninstall WireGuard just by running the script.

./uninstall_wireguard.sh

This repository is a fork of @whiskerz007's original ubnt_get_wireguard repository which doesn't seem to be being maintained anymore.

One pull request from the original repository by @dcava has been merged.

Further small changes have been added by me.

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Shell 100.0%