k4yt3x / wg-meshconf

WireGuard full mesh configuration generator.
GNU General Public License v3.0
938 stars 105 forks source link

Multiple preup, postup, predown, postdown commands #36

Open klovatt opened 1 year ago

klovatt commented 1 year ago

Hi,

I'm experimenting to see how I can make this work in my environment.

On first passs it is very good, allowing for site to site (multiple subnet) mesh plus individual enpoints (e.g. phone, laptop).

I tried to add multiple iptables commands, but no luck. The pre/post actions seem to be single command using either csv or command line.

Could they be treated in a similar fashion to the addresses ( a comma separated list)?

Thanks!

TheAnachronism commented 9 months ago

Agreed, just ran into this myself of needing multiple preup commands. @k4yt3x is this possible?

rudolfbyker commented 3 months ago

I also need this.

Workaround for now: Chain commands using &&.

sysctl -w net.ipv4.ip_forward=1 && iptables … && etc && foo && bar