-{ lib, pkgs, pkgsPrevious, config, myconfig, mylibs, ... }:
+{ lib, pkgs, config, myconfig, mylibs, ... }:
let
- mastodon = pkgsPrevious.callPackage ./mastodon.nix {
+ mastodon = pkgs.callPackage ./mastodon.nix {
inherit (mylibs) fetchedGithub;
env = myconfig.env.tools.mastodon;
};
socketsDir = "/run/mastodon";
gems = bundlerEnv {
name = "mastodon-env";
- ruby = ruby_2_5;
+ # https://git.immae.eu/mantisbt/view.php?id=131
+ ruby = ruby_2_5.overrideAttrs(old: {
+ postInstall = builtins.replaceStrings [" --destdir $GEM_HOME"] [""] old.postInstall;
+ });
gemset = ./gemset.nix;
gemdir = (fetchedGithub ./mastodon.json).src;
groups = [ "default" "production" "test" "development" ];
pkgConfig = {
uws = {
postInstall = ''
- node-gyp rebuild > build_log.txt 2>&1 || true
+ npx node-gyp rebuild > build_log.txt 2>&1 || true
'';
- buildInputs = with pkgs; [ nodePackages.node-gyp ];
};
node-zopfli = {
postInstall = ''
- node-pre-gyp install --fallback-to-build
+ npx node-pre-gyp install --fallback-to-build
'';
- buildInputs = with pkgs; [ nodePackages.node-pre-gyp ];
};
node-sass = {
buildInputs = with pkgs; [ libsass python ];
postInstall = let
nodeHeaders = pkgs.fetchurl {
url = "https://nodejs.org/download/release/v${pkgs.nodejs.version}/node-v${pkgs.nodejs.version}-headers.tar.gz";
- sha256 = "12zzsf8my43b8qnlacp871ih5vqafl2vlpqp51xp6h3gckn2frwy";
+ sha256 = "16f20ya3ys6w5w6y6l4536f7jrgk4gz46bf71w1r1xxb26a54m32";
};
in
''
nixops set-args --argstr privateFiles "$TEMP"
# This will automatically upgrade to latest version at each build
-# nixpkgsNext="https://nixos.org/channels/nixos-19.03/nixexprs.tar.xz"
-nixpkgsNext="https://releases.nixos.org/nixos/19.03/nixos-19.03beta171840.23fd1394dc6/nixexprs.tar.xz"
-nixpkgsPrevious="https://releases.nixos.org/nixos/18.09/nixos-18.09.1834.9d608a6f592/nixexprs.tar.xz"
-nixpkgs="$nixpkgsNext"
+# nixpkgs="https://nixos.org/channels/nixos-19.03/nixexprs.tar.xz"
+nixpkgs="https://releases.nixos.org/nixos/19.03/nixos-19.03beta171840.23fd1394dc6/nixexprs.tar.xz"
+nixpkgsPrevious="$nixpkgs"
+nixpkgsNext="$nixpkgs"
export NIX_PATH="ssh-config-file=$(dirname $DIR)/ssh/config:nixpkgs=$nixpkgs:nixpkgsNext=$nixpkgsNext:nixpkgsPrevious=$nixpkgsPrevious"
nixops "$@"