uboot: (firmwareOdroidC2/C4) don't invoke patch tool, use patches = [] instead
https://github.com/NixOS/nixpkgs/blob/master/pkgs/stdenv/generic/setup.sh#L948 this can do it nicely. Signed-off-by: Anton Arapov <anton@deadbeef.mx>
This commit is contained in:
commit
56de2bcd43
30691 changed files with 3076956 additions and 0 deletions
58
pkgs/servers/owncast/default.nix
Normal file
58
pkgs/servers/owncast/default.nix
Normal file
|
|
@ -0,0 +1,58 @@
|
|||
{ lib, buildGoModule, fetchFromGitHub, nixosTests, bash, which, ffmpeg, makeWrapper, coreutils, ... }:
|
||||
|
||||
buildGoModule rec {
|
||||
pname = "owncast";
|
||||
version = "0.0.11";
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "owncast";
|
||||
repo = "owncast";
|
||||
rev = "v${version}";
|
||||
sha256 = "sha256-SVe7CH+qx3hFZ/cay6Hh5+vx0ncHACiNSM6k7fCDH18=";
|
||||
};
|
||||
|
||||
vendorSha256 = "sha256-19FTfUCG1omk5y1HC2yb7/0CM2x6k5BGSM+sZwlKrxY=";
|
||||
|
||||
propagatedBuildInputs = [ ffmpeg ];
|
||||
|
||||
nativeBuildInputs = [ makeWrapper ];
|
||||
|
||||
preInstall = ''
|
||||
mkdir -p $out
|
||||
cp -r $src/{static,webroot} $out
|
||||
'';
|
||||
|
||||
postInstall = let
|
||||
|
||||
setupScript = ''
|
||||
[ ! -d "$PWD/webroot" ] && (
|
||||
${coreutils}/bin/cp --no-preserve=mode -r "${placeholder "out"}/webroot" "$PWD"
|
||||
)
|
||||
|
||||
[ ! -d "$PWD/static" ] && (
|
||||
${coreutils}/bin/ln -s "${placeholder "out"}/static" "$PWD"
|
||||
)
|
||||
'';
|
||||
in ''
|
||||
wrapProgram $out/bin/owncast \
|
||||
--run '${setupScript}' \
|
||||
--prefix PATH : ${lib.makeBinPath [ bash which ffmpeg ]}
|
||||
'';
|
||||
|
||||
installCheckPhase = ''
|
||||
runHook preCheck
|
||||
$out/bin/owncast --help
|
||||
runHook postCheck
|
||||
'';
|
||||
|
||||
passthru.tests.owncast = nixosTests.testOwncast;
|
||||
|
||||
meta = with lib; {
|
||||
description = "self-hosted video live streaming solution";
|
||||
homepage = "https://owncast.online";
|
||||
license = licenses.mit;
|
||||
platforms = platforms.unix;
|
||||
maintainers = with maintainers; [ MayNiklas ];
|
||||
};
|
||||
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue