blob: 40488aff18a63b83c06b815d0b007c7a29b8986c (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
|
{ lib, stdenv, fetchFromGitHub, writeText, nixosTests }:
stdenv.mkDerivation rec {
pname = "limesurvey";
version = "6.1.2+230606";
src = fetchFromGitHub {
owner = "LimeSurvey";
repo = "LimeSurvey";
rev = version;
hash = "sha256-a89Kdr9XV1TSCoWxYrU0j8ec7rAcIlU/bgLtRjdzqbg=";
};
phpConfig = writeText "config.php" ''
<?php
return require(getenv('LIMESURVEY_CONFIG'));
?>
'';
installPhase = ''
runHook preInstall
mkdir -p $out/share/limesurvey
cp -r . $out/share/limesurvey
cp ${phpConfig} $out/share/limesurvey/application/config/config.php
runHook postInstall
'';
passthru.tests = {
smoke-test = nixosTests.limesurvey;
};
meta = with lib; {
description = "Open source survey application";
license = licenses.gpl2;
homepage = "https://www.limesurvey.org";
maintainers = with maintainers; [offline];
platforms = with platforms; unix;
};
}
|