37 lines
767 B
Nix
37 lines
767 B
Nix
{ stdenv
|
|
, dpkg
|
|
, fetchurl
|
|
, unzip
|
|
}:
|
|
|
|
stdenv.mkDerivation rec {
|
|
name = "unifi-controller-${version}";
|
|
version = "5.5.11";
|
|
|
|
src = fetchurl {
|
|
url = "https://www.ubnt.com/downloads/unifi/5.5.11-5107276ec2/unifi_sysvinit_all.deb";
|
|
sha256 = "1jsixz7g7h7fdwb512flcwk0vblrsxpg4i9jdz7r72bkmvnxk7mm";
|
|
};
|
|
|
|
buildInputs = [ dpkg ];
|
|
|
|
unpackPhase = ''
|
|
dpkg-deb -x ${src} ./
|
|
'';
|
|
|
|
doConfigure = false;
|
|
|
|
installPhase = ''
|
|
mkdir -p $out
|
|
cd ./usr/lib/unifi
|
|
cp -ar dl lib webapps $out
|
|
'';
|
|
|
|
meta = with stdenv.lib; {
|
|
homepage = http://www.ubnt.com/;
|
|
description = "Controller for Ubiquiti UniFi accesspoints";
|
|
license = licenses.unfree;
|
|
platforms = platforms.unix;
|
|
maintainers = with maintainers; [ wkennington ];
|
|
};
|
|
}
|