]> git.immae.eu Git - perso/Immae/Config/Nix.git/commitdiff
Purify mediagoblin website
authorIsmaël Bouya <ismael.bouya@normalesup.org>
Thu, 24 Jan 2019 10:29:24 +0000 (11:29 +0100)
committerIsmaël Bouya <ismael.bouya@normalesup.org>
Thu, 24 Jan 2019 10:31:24 +0000 (11:31 +0100)
This was the last known step to purify the install.

Fixes https://git.immae.eu/mantisbt/view.php?id=79
Fixes https://git.immae.eu/mantisbt/view.php?id=114

default.nix
virtual/modules/websites/tools/mediagoblin/bower-packages.nix [new file with mode: 0644]
virtual/modules/websites/tools/mediagoblin/mediagoblin.nix

index 7e7ef0a9aa4b17bc4348345a00b779c963cadbf9..75e1e0a391035babda8137151457dff11b317da2 100644 (file)
@@ -312,4 +312,5 @@ in
     stgit = gitAndTools.stgit;
     inherit bundix;
     inherit yarn2nix;
+    bower2nix = nodePackages.bower2nix;
   })
diff --git a/virtual/modules/websites/tools/mediagoblin/bower-packages.nix b/virtual/modules/websites/tools/mediagoblin/bower-packages.nix
new file mode 100644 (file)
index 0000000..03af849
--- /dev/null
@@ -0,0 +1,8 @@
+# Generated by bower2nix v3.2.0 (https://github.com/rvl/bower2nix)
+{ fetchbower, buildEnv }:
+buildEnv { name = "bower-env"; ignoreCollisions = true; paths = [
+  (fetchbower "jquery" "2.1.4" "~2.1.3" "1ywrpk2xsr6ghkm3j9gfnl9r3jn6xarfamp99b0bcm57kq9fm2k0")
+  (fetchbower "video.js" "4.11.4" "~4.11.4" "05prdvyk0rxbkh7sdd0d9ns5l5crwvc68wzkyqmrdjw367pcv8sn")
+  (fetchbower "leaflet" "0.7.7" "~0.7.3" "0jim285bljmxxngpm3yx6bnnd10n2whwkgmmhzpcd1rdksnr5nca")
+  (fetchbower "tinymce" "4.1.10" "~4.1.7" "16jyvdb9bq8gjwhs69q8p88vdixalajrz81nsmbrzzxhkih57dyx")
+]; }
index 2e62242cb46192fd8d6625e1079b6e5d70597e64..54470a485220607504ff065d3e5a703d4e608b4e 100644 (file)
@@ -1,4 +1,4 @@
-{ env, makeWrapper, stdenv, writeText, fetchurl, fetchedGit, fetchedGithub, which, python3, pkgs, automake, autoconf, nodejs, nodePackages, git, cacert }:
+{ env, makeWrapper, stdenv, writeText, fetchurl, buildBowerComponents, fetchedGit, fetchedGithub, which, python3, pkgs, automake, autoconf, nodejs, nodePackages, git, cacert }:
 let
   plugins = {
     basicsearch = stdenv.mkDerivation (fetchedGithub ./mediagoblin-plugin-basicsearch.json // rec {
@@ -108,6 +108,11 @@ in
   rec {
     socketsDir = "/run/mediagoblin";
     varDir = "/var/lib/mediagoblin";
+    bowerComponents = buildBowerComponents {
+      name = "mediagoblin-bower-components";
+      generated = ./bower-packages.nix;
+      src = (fetchedGit ./mediagoblin.json).src;
+    };
     mediagoblin = stdenv.mkDerivation (fetchedGit ./mediagoblin.json // rec {
       preConfigure = ''
         # ./bootstrap.sh
@@ -120,6 +125,8 @@ in
         '';
       configureFlags = [ "--with-python3" "--without-virtualenv" ];
       postBuild = ''
+        cp -a ${bowerComponents}/bower_components/* extlib
+        chmod -R u+w extlib
         make extlib
         '';
       installPhase = ''