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

Allow installation of locally stored wireguard packages #15

Open
yubiuser opened this issue May 8, 2020 · 4 comments
Open

Allow installation of locally stored wireguard packages #15

yubiuser opened this issue May 8, 2020 · 4 comments

Comments

@yubiuser
Copy link

yubiuser commented May 8, 2020

It would be nice to be able to install local wireguad.deb packages. This might help troubleshooting if one wants to go back to an older wireguard version which has been stored locally instead of always installing the latest version.

Thanks

./wireguard.sh install local /PATH/TO/wireguad.deb

@mafredri
Copy link
Owner

mafredri commented May 8, 2020

Do you mean a .deb you manually download onto the device or from the cache folder? Currently the cache folder is wiped on every upgrade to prevent piling up files and using up storage on the device. The folders main purpose is to store the .deb for restoring the installation after a firmware upgrade.

Installing specific versions has been on the todo, but not a priority. We could add a feature for the install command so that it can take an extra parameter which is either a local .deb or a version number (e.g. 1.0.20200506-1) which is then downloaded from the repo. For the latter, it would be good to add another command which lists all available versions (from the repo), e.g. list.

@yubiuser
Copy link
Author

yubiuser commented May 8, 2020

I meant manually download deb, not from cache.

With your further explanation I see four possible features here

  1. install a .deb manually downloaded onto the device
  2. (re) install latest version from cache
  3. install specific version from github
  4. list all available versions from github

My wishes would be the order 4), 3) .. 1)..... ..... ... 2)

@JiriPodhorny
Copy link

Hello,

just some (maybe useful) hints for EdgeRouter (most probably not valid for USG, I don't have any)

Special folders:

/config/data/firstboot/install-packages/ for .deb packages that would be automatically installed on first boot after firmware upgrade (I have my wireguard.deb here)

/config/scripts/post-config.d/ any executable file in this folder will be executed once after system boots up (after config.boot is executed)

/config/scripts/pre-config.d/ scripts to be executed on boot prior config.boot is executed

/config/scripts/firstboot.d/ contains script run only on first boot after firmware upgrade

@mafredri
Copy link
Owner

@JiriPodhorny thanks. I recently became aware of (some) of these while digging through the USG rootfs files, and indeed, I believe these work the same on the USG as well.

It's worth considering the use of /config/data/firstboot/install-packages/ instead of the current method as it should happen early enough so that we don't have to reload the configuration. Although, migrating all users might be more pain than it's worth (since the firmware upgrade process works well as-is).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants