root@openvpn:/etc/openvpn# cat server.conf
port 1194
proto udp
multihome
dev tun
user nobody
group nogroup
persist-key
persist-tun
keepalive 10 120
topology subnet
server 10.8.0.0 255.255.255.0
ifconfig-pool-persist ipp.txt
push "dhcp-option DNS 192.168.10.144"
push "dhcp-option DNS 192.168.10.17"
push "dhcp-option DNS 192.168.10.18"
#push "route 10.200.0.0 255.255.255.0"
push "route 192.168.0.0 255.255.240.0"
push "route 192.168.150.0 255.255.255.0"
#push "redirect-gateway"
dh none
ecdh-curve prime256v1
tls-crypt tls-crypt.key 0
crl-verify crl.pem
ca ca.crt
cert server.crt
key server.key
auth SHA256
cipher AES-256-CBC
ncp-ciphers AES-128-GCM:AES-256-CBC
tls-server
tls-version-min 1.2
tls-cipher TLS-ECDHE-ECDSA-WITH-AES-128-GCM-SHA256
status /var/log/openvpn/status.log
verb 3
duplicate-cn
# interfaces(5) file used by ifup(8) and ifdown(8)
auto lo
iface lo inet loopback
auto br1
iface br1 inet dhcp
bridge_ports enp3s0
bridge_stp off
bridge_fd 0.0
dns-search blabla.ru
dns-search blabla.ru
#!/bin/bash
while true; do
echo -n "Please enter an folder -> "
read folderdcheck
if [ ! -d "$folderdcheck" ]; then
echo "$folderdcheck is not exist."
mkdir -p $folderdcheck
echo "$folderdcheck is created."
break
else
echo "$folderdcheck exist."
fi
done
echo "Program terminated."
#!/bin/bash
# в качестве параметра скрипта указываем папку
# берем результат работы в переменную
BLOCK=$(df $1 | awk '/dev/ {print $1}')
# если в строке содержится "by-uuid" то ...
if [[ $BLOCK == *"by-uuid"* ]] ;
then
# обрабатываем одним способом
blkid -U $(echo $BLOCK | cut -d/ -f5)
else
# если "by-uuid" нет, то просто выводим.
echo $BLOCK
fi