Skip to content
This repository has been archived by the owner on Apr 25, 2023. It is now read-only.

Read in existing server config #7

Open
sidewaysglance opened this issue Oct 14, 2019 · 8 comments
Open

Read in existing server config #7

sidewaysglance opened this issue Oct 14, 2019 · 8 comments
Labels
enhancement New feature or request good first issue Good for newcomers

Comments

@sidewaysglance
Copy link

It would be a fantastic feature to be able to read in a normal server conf file and have it create it's config.json from it.

@sidewaysglance sidewaysglance added the enhancement New feature or request label Oct 14, 2019
@dmitrydvornichenko
Copy link

@tozjerimiah normal server config requires a private key of server interface and public keys of peers. In this wg-ui config.json, you have to specify both private and public keys of peers. To create config.json from an existing server config, you'll need an additional source where private keys of peers will be stored.
I'm storing those keys in an ansible role.

@suom1 suom1 added the good first issue Good for newcomers label May 5, 2020
@seppi91
Copy link

seppi91 commented May 9, 2020

As web-ui doesn't have any knowledge about the private-keys of these peers, we could make them read-only for now. Maybe we could enhance this feature to fill in the private key at a later point of time, and therefore be able to generate a config as well but I would suggest to postpone such functionality.

@ecofintech
Copy link

ecofintech commented Aug 10, 2020

Hello,
I am testing wg-ui, it is a great solution.
Can be possible you explain more in detail how to use existent configuration? I will appreciate it
thanks

@ecofintech
Copy link

...or at least any way to replicate the current configuration using the command line options..
Today I needed to reboot the server because the interface build up by wg-ui created some kind of conflict with other own interface. But I guess it is because I used the same private keys in both of them, Anyways, it was strange because with wg show the wg-ui interface was remaining active even after killing the process.
Still investigating how I can use it properly...

@pw44
Copy link

pw44 commented Aug 20, 2020

Hi all,

i already have wireguard working. I could not find how to use the current configuration with wg-ui.

Any hint in how to have it productive, without having to start a new sitewide configuration?

Best regards,

@eisengrau
Copy link

I second this, it would be nice if it could read the current configs of WG, eg. already existent /etc/wireguard/wg0.conf, or if someone has a service set up, like systemctl status wg-quick@wg0

@alexlii1971
Copy link

Quite confused, there is no any document or tutorial to show how to setup with Wireguard wg0 configuration?

or did I missed any thing?

@ramikhreim
Copy link

Kindly should i copy the wireguard config from (sudo nano /etc/wireguard/wg0.conf) to /data/config.json?
how the UI read the current wireguard config?
I have Ubuntu with wireguard installed and running , i used the docker run like this:
sudo docker run --rm -it --privileged --entrypoint "/wireguard-ui" -v /tmp/wireguard-ui:/data -p 8080:8080 embarkstudios/wireguard-ui:latest --data-dir=/data --log-level=debug --client-ip-range="10.50.0.6/24" --wg-endpoint="xxxxxxx:54321" --wg-listen-port=54321 --wg-device-name="wg0" --max-number-client-config=0 --wg-allowed-ips=xxxxxxxxxxxxx --wg-dns="1.1.1.1" --nat-device="ens5" --wg-keepalive="25" --nat

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
enhancement New feature or request good first issue Good for newcomers
Projects
None yet
Development

No branches or pull requests

9 participants