yum groupinstall "Development Tools"
yum install openssl-devel lzo-devel
cd /tmp/
wget https://dl.fedoraproject.org/pub/fedora/linux/releases/28/Everything/source/tree/Packages/t/tinc-1.0.33-2.fc28.src.rpm
rpm2cpio tinc-1.0.33-2.fc28.src.rpm | cpio -idmv
mkdir -p ~/rpmbuild/{BUILD,BUILDROOT,RPMS,SOURCES,SPECS,SRPMS}
wget https://www.tinc-vpn.org/packages/tinc-1.0.34.tar.gz -P ~/rpmbuild/SOURCES/
sed -i 's|1\.0\.33|1.0.34|g' tinc.spec
mv tinc.spec ~/rpmbuild/SPECS/
cd ~/rpmbuild/SPECS
rpmbuild -ba tinc.spec



/usr/lib/systemd/system/tinc@.service:
--- cut ---
[Unit]
Description=Tinc net %i
Documentation=info:tinc
Documentation=man:tinc(8) man:tinc.conf(5)
Documentation=http://tinc-vpn.org/docs/
PartOf=tinc.service
ReloadPropagatedFrom=tinc.service

[Service]
Type=simple
WorkingDirectory=/etc/tinc/%i
ExecStart=/usr/sbin/tincd --net=%i --no-detach --debug=3 --logfile=/var/log/tinc.%i.log
ExecReload=/usr/sbin/tincd -n %i -kHUP
KillMode=mixed
Restart=on-failure
RestartSec=5
TimeoutStopSec=5

[Install]
WantedBy=tinc.service
--- cut ---

#!/bin/sh
CURL_OPTS='-x socks5h://10.35.215.218:443 -sS'

file_html=/tmp/index.html
file_rpms=/tmp/rpm_files.lst
file_rpms_local=/tmp/rpm_files_local.lst

for TYPE in updates extras; do
    mirror_base_url=http://vault.centos.org/5.11/${TYPE}/x86_64/RPMS/
    local_rpm_directory=/var/www/repo.gd.rt.ru/CentOS/5/${TYPE}

    echo "type=${TYPE}"

    rm -f ${file_html} ${file_rpms}
    curl ${CURL_OPTS} ${mirror_base_url} -o ${file_html}
    grep -Po '(?<=href=")[^"]*' $file_html | grep 'x86_64.rpm' | sort -n > $file_rpms

    ls -1 ${local_rpm_directory} | sort -n > ${file_rpms_local}

if [[ $(stat -c%s ${file_rpms_local}) != $(stat -c%s ${file_rpms}) ]]; then
    echo "Downloading.."
#    diff ${file_rpms_local} ${file_rpms}
    sed -i -e "s|^|${mirror_base_url}|" ${file_rpms}
    cd ${local_rpm_directory}

    xargs -n 1 curl ${CURL_OPTS} -O < ${file_rpms}
    rm -f ${file_html} ${file_rpms}
else
    echo "Nothing to do."
fi
done​

Если докер находится за прокси, постоянно видим такую ошибку:

[root@mist ~]# cd /tmp/; docker-compose up -d
Pulling traefik (traefik:v1.5)...
ERROR: Get https://registry-1.docker.io/v2/: dial tcp 54.165.149.19:443: connect: connection refused


делаем следующее:

$ mkdir -p /etc/systemd/system/docker.service.d

$ cat < EOF >> /etc/systemd/system/docker.service.d/http-proxy.conf
[Service]
Environment="HTTP_PROXY=http://proxy.example.com:80/" "HTTPS_PROXY=http://proxy.example.com:80/" "NO_PROXY=localhost,127.0.0.1"
EOF
$ systemctl daemon-reload
$ systemctl restart docker
$ systemctl show --property=Environment docker
https://docs.docker.com/config/daemon/systemd/#httphttps-proxy