Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Adds multiple openvpn server capability, a new variable $SERVER_ID can be passed it will create then the conf in /etc/openvpn/server.$SERVER_ID.conf and all server files will be placed in /etc/openvpn/server.$SERVER_ID/ .
for example
SERVER_ID=my_openvpn ./openvpn-install.sh
It covers the server creation, the removal and the client creation.
(note: also changes the way how it proposes the public ip in install server questions. it tries to detect not private ips and if cannot find it fallbacks to private ips)
There are some pending tasks:
The ipv6 address for tunnel.
The ipv4 for the tunnel is defined taking the most great second octet found in all servers configs: for example if there's a conf with 10.10.0.1 it will create the next openvpn server using 10.11.0.1.
This logic is not implemented with ipv6.
unbound
unbound part, as I don't know if it can accept multiple servers.