mirror of
https://github.com/ilyakooo0/nixpkgs.git
synced 2024-12-27 05:43:50 +03:00
update-resolv-conf: 20141003 -> 2016-04-24
This commit is contained in:
parent
bdc700c23a
commit
49fe339b09
@ -1,27 +1,32 @@
|
||||
{ stdenv, fetchgit, makeWrapper, openresolv, coreutils }:
|
||||
{ stdenv, lib, fetchFromGitHub, makeWrapper, openresolv, coreutils, which, systemd }:
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
name = "update-resolv-conf-20141003";
|
||||
let
|
||||
binPath = lib.makeBinPath [ coreutils openresolv which systemd ];
|
||||
|
||||
src = fetchgit {
|
||||
url = https://github.com/masterkorp/openvpn-update-resolv-conf/;
|
||||
rev = "dd968419373bce71b22bbd26de962e89eb470670";
|
||||
sha256 = "0j7mg66lqhgvhybgbn98y7i5skj1ify41hmb0yhkx2xrli8027b9";
|
||||
in stdenv.mkDerivation rec {
|
||||
name = "update-resolv-conf-2016-04-24";
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "masterkorp";
|
||||
repo = "openvpn-update-resolv-conf";
|
||||
rev = "994574f36b9147cc78674a5f13874d503a625c98";
|
||||
sha256 = "1rvzlaj53k8s09phg4clsyzlmf44dmwwyvg0nbg966sxp3xsqlxc";
|
||||
};
|
||||
|
||||
nativeBuildInputs = [ makeWrapper ];
|
||||
|
||||
installPhase = ''
|
||||
install -Dm555 update-resolv-conf.sh $out/libexec/openvpn/update-resolv-conf
|
||||
sed -i 's,^\(RESOLVCONF=\).*,\1resolvconf,' $out/libexec/openvpn/update-resolv-conf
|
||||
install -Dm555 update-systemd-network.sh $out/libexec/openvpn/update-systemd-network
|
||||
|
||||
wrapProgram $out/libexec/openvpn/update-resolv-conf \
|
||||
--prefix PATH : ${coreutils}/bin:${openresolv}/sbin
|
||||
for i in $out/libexec/openvpn/*; do
|
||||
wrapProgram $i --prefix PATH : ${binPath}
|
||||
done
|
||||
'';
|
||||
|
||||
meta = with stdenv.lib; {
|
||||
description = "Script to update your /etc/resolv.conf with DNS settings that come from the received push dhcp-options";
|
||||
homepage = https://github.com/masterkorp/openvpn-update-resolv-conf/;
|
||||
homepage = "https://github.com/masterkorp/openvpn-update-resolv-conf/";
|
||||
maintainers = with maintainers; [ abbradar ];
|
||||
license = licenses.gpl2;
|
||||
platforms = platforms.unix;
|
||||
|
Loading…
Reference in New Issue
Block a user