[PATCH] Adding support for reloading configuration via systemd

Jason A. Donenfeld Jason at zx2c4.com
Fri Jul 24 11:14:52 CEST 2020


On Fri, Jul 24, 2020 at 10:30 AM Tomcsanyi, Domonkos <domi at tomcsanyi.net> wrote:
>
> Signed-off-by: Domonkos P. Tomcsanyi <domi at tomcsanyi.net>
> ---
> src/systemd/wg-quick at .service | 1 +
> 1 file changed, 1 insertion(+)
>
> diff --git a/src/systemd/wg-quick at .service b/src/systemd/wg-quick at .service
> index a9cbb58..8eb040b 100644
> --- a/src/systemd/wg-quick at .service
> +++ b/src/systemd/wg-quick at .service
> @@ -15,6 +15,7 @@ Type=oneshot
> RemainAfterExit=yes
> ExecStart=/usr/bin/wg-quick up %i
> ExecStop=/usr/bin/wg-quick down %i
> +ExecReload=/bin/bash -c '/usr/bin/wg syncconf %i <(/usr/bin/wg-quick strip
> %i)'
> Environment=WG_ENDPOINT_RESOLUTION_RETRIES=infinity
>
> [Install]
> --
> 2.17.1
>
> Not the cleanest solution, but I think it might help a lot of people, so I'm
> submitting it.

This actually doesn't seem too bad to me. Are there cleaner solutions
that I'm not thinking of that I should consider before applying this
patch?


More information about the WireGuard mailing list