summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'net-vpn/openvpn/openvpn-9999.ebuild')
-rw-r--r--net-vpn/openvpn/openvpn-9999.ebuild44
1 files changed, 30 insertions, 14 deletions
diff --git a/net-vpn/openvpn/openvpn-9999.ebuild b/net-vpn/openvpn/openvpn-9999.ebuild
index befc78d0d7bb..b2945c23a0f7 100644
--- a/net-vpn/openvpn/openvpn-9999.ebuild
+++ b/net-vpn/openvpn/openvpn-9999.ebuild
@@ -14,7 +14,7 @@ LICENSE="GPL-2"
SLOT="0"
KEYWORDS=""
-IUSE="down-root examples inotify iproute2 libressl lz4 +lzo mbedtls pam"
+IUSE="down-root examples inotify iproute2 libressl +lz4 +lzo mbedtls pam"
IUSE+=" pkcs11 +plugins selinux +ssl systemd test userland_BSD"
RESTRICT="!test? ( test )"
@@ -118,19 +118,35 @@ pkg_postinst() {
elog "http://tuntaposx.sourceforge.net"
fi
- elog "The openvpn init script expects to find the configuration file"
- elog "openvpn.conf in /etc/openvpn along with any extra files it may need."
- elog ""
- elog "To create more VPNs, simply create a new .conf file for it and"
- elog "then create a symlink to the openvpn init script from a link called"
- elog "openvpn.newconfname - like so"
- elog " cd /etc/openvpn"
- elog " ${EDITOR##*/} foo.conf"
- elog " cd /etc/init.d"
- elog " ln -s openvpn openvpn.foo"
- elog ""
- elog "You can then treat openvpn.foo as any other service, so you can"
- elog "stop one vpn and start another if you need to."
+ if systemd_is_booted || has_version sys-apps/systemd; then
+ elog "In order to use OpenVPN with systemd please use the correct systemd service file."
+ elog ""
+ elog "server:"
+ elog ""
+ elog "- Place your server configuration file in /etc/openvpn/server"
+ elog "- Use the openvpn-server@.service like so"
+ elog "systemctl start openvpn-server@{Server-config}"
+ elog ""
+ elog "client:"
+ elog ""
+ elog "- Place your client configuration file in /etc/openvpn/client"
+ elog "- Use the openvpn-client@.service like so:"
+ elog "systemctl start openvpn-client@{Client-config}"
+ else
+ elog "The openvpn init script expects to find the configuration file"
+ elog "openvpn.conf in /etc/openvpn along with any extra files it may need."
+ elog ""
+ elog "To create more VPNs, simply create a new .conf file for it and"
+ elog "then create a symlink to the openvpn init script from a link called"
+ elog "openvpn.newconfname - like so"
+ elog " cd /etc/openvpn"
+ elog " ${EDITOR##*/} foo.conf"
+ elog " cd /etc/init.d"
+ elog " ln -s openvpn openvpn.foo"
+ elog ""
+ elog "You can then treat openvpn.foo as any other service, so you can"
+ elog "stop one vpn and start another if you need to."
+ fi
if grep -Eq "^[ \t]*(up|down)[ \t].*" "${ROOT}/etc/openvpn"/*.conf 2>/dev/null ; then
ewarn ""