appgate-sdp: 5.1.2 -> 5.3.2

This commit is contained in:
Yurii Matsiuk 2021-01-11 11:51:00 +01:00
parent b97a90532e
commit ee73665fa0
No known key found for this signature in database
GPG Key ID: 61302290298601AA

View File

@ -20,6 +20,8 @@
, iproute
, krb5
, lib
, mesa
, libdrm
, libX11
, libXScrnSaver
, libXcomposite
@ -65,6 +67,8 @@ let
gtk3
icu
krb5
mesa
libdrm
libX11
libXScrnSaver
libXcomposite
@ -92,11 +96,11 @@ let
in
stdenv.mkDerivation rec {
pname = "appgate-sdp";
version = "5.1.2";
version = "5.3.2";
src = fetchurl {
url = "https://bin.appgate-sdp.com/5.1/client/appgate-sdp_${version}_amd64.deb";
sha256 = "0v4vfibg1giml3vfz2w7qypqzymvfchi5qm6vfagah2vfbkw7xc2";
url = "https://bin.appgate-sdp.com/${lib.versions.majorMinor version}/client/appgate-sdp_${version}_amd64.deb";
sha256 = "123d4mx2nsh8q3ckm4g2chdcdwgg0cz9cvhiwjggxzvy7j6bqgy4";
};
dontConfigure = true;
@ -123,26 +127,35 @@ stdenv.mkDerivation rec {
cp -r $out/usr/share $out/share
for file in $out/opt/appgate/linux/appgate-resolver.pre \
$out/opt/appgate/linux/appgate-dumb-resolver.pre \
$out/lib/systemd/system/appgatedriver.service \
$out/lib/systemd/system/appgate-dumb-resolver.service \
$out/lib/systemd/system/appgate-resolver.service
$out/opt/appgate/linux/appgate-dumb-resolver.pre
do
substituteInPlace $file \
--replace "/bin/sh" "${bash}/bin/sh" \
--replace "/opt/" "$out/opt/" \
--replace "/usr/sbin/dnsmasq" "${dnsmasq}/bin/dnsmasq" \
--replace "InaccessiblePaths=/mnt /srv /boot /media" "InaccessiblePaths=-/mnt -/srv -/boot -/media" \
--replace "cat" "${coreutils}/bin/cat" \
--replace "chattr" "${e2fsprogs}/bin/chattr" \
--replace "mv" "${coreutils}/bin/mv" \
--replace "pkill" "${procps}/bin/pkill"
done
for file in $out/lib/systemd/system/appgatedriver.service \
$out/lib/systemd/system/appgate-dumb-resolver.service \
$out/lib/systemd/system/appgate-resolver.service
do
substituteInPlace $file \
--replace "/bin/sh" "${bash}/bin/sh" \
--replace "/opt/" "$out/opt/" \
--replace "chattr" "${e2fsprogs}/bin/chattr" \
--replace "mv" "${coreutils}/bin/mv"
done
substituteInPlace $out/lib/systemd/system/appgatedriver.service \
--replace "InaccessiblePaths=/mnt /srv /boot /media" "InaccessiblePaths=-/mnt -/srv -/boot -/media"
substituteInPlace $out/lib/systemd/system/appgate-resolver.service \
--replace "/usr/sbin/dnsmasq" "${dnsmasq}/bin/dnsmasq"
substituteInPlace $out/opt/appgate/linux/nm.py --replace "/usr/sbin/dnsmasq" "${dnsmasq}/bin/dnsmasq"
substituteInPlace $out/opt/appgate/linux/set_dns \
--replace "service appgate-resolver stop" "${systemd.out}/bin/systemctl stop appgate-resolver" \
--replace "/etc/appgate.conf" "$out/etc/appgate.conf"
substituteInPlace $out/opt/appgate/linux/set_dns --replace "/etc/appgate.conf" "$out/etc/appgate.conf"
'';