avanc / photOS

Operating System for digital photo frames
Other
85 stars 14 forks source link

Wireguard Support #90

Open avanc opened 2 years ago

tzockt commented 1 year ago

Hi, I have tested their trial version of Wireguard. It worked quite well but unfortunately you can't put it into the autostart. Therefore here are some notes for improvement:

On the one hand you need a start script under /etc/init.d/ see link https://www.procustodibus.com/blog/2021/06/wireguard-sysv-init-script/ And you need access to the folder /etc/wireguard or you manage to change the directory to /data/etc/wireguard

VG TZockt

avanc commented 1 year ago

If you want to change on the target, you have to remount the root partition to get write access

mount -o remount,rw /

If you want to change the build of the image you can add the file under board/raspberrypi/overlay/etc/init.d/

avanc commented 1 year ago

I would suggest to let Wireguard let search the config in /data/etc/wireguard

$command up /data/etc/wireguard/conf.conf

according to https://manpages.debian.org/unstable/wireguard-tools/wg-quick.8.en.html

And in the init script you could check if the config file exists and exit otherwise without doing anything similar to https://github.com/avanc/photOS/blob/master/package/samba4/S91smb#L3