summary refs log tree commit diff
path: root/pkgs/development/tools/vagrant
diff options
context:
space:
mode:
authorPeter Hoeg <peter@speartail.com>2016-09-05 20:44:34 +0800
committerFranz Pletz <fpletz@fnordicwalking.de>2016-09-05 14:44:34 +0200
commita359d330dc10701f9f6aa318d17c9dffcaa25ca7 (patch)
tree0621fe9b9f108403077550d8235ee0d33cb98e13 /pkgs/development/tools/vagrant
parent03e70ebcc6d97dc085fb19e3909a3298c58ec3e0 (diff)
downloadnixlib-a359d330dc10701f9f6aa318d17c9dffcaa25ca7.tar
nixlib-a359d330dc10701f9f6aa318d17c9dffcaa25ca7.tar.gz
nixlib-a359d330dc10701f9f6aa318d17c9dffcaa25ca7.tar.bz2
nixlib-a359d330dc10701f9f6aa318d17c9dffcaa25ca7.tar.lz
nixlib-a359d330dc10701f9f6aa318d17c9dffcaa25ca7.tar.xz
nixlib-a359d330dc10701f9f6aa318d17c9dffcaa25ca7.tar.zst
nixlib-a359d330dc10701f9f6aa318d17c9dffcaa25ca7.zip
vagrant: 1.8.4 -> 1.8.5 (#18283)
Includes https://github.com/mitchellh/vagrant/pull/7611 to fix issue with permissions on ~/.ssh/authorized_keys.
Diffstat (limited to 'pkgs/development/tools/vagrant')
-rw-r--r--pkgs/development/tools/vagrant/default.nix40
1 files changed, 25 insertions, 15 deletions
diff --git a/pkgs/development/tools/vagrant/default.nix b/pkgs/development/tools/vagrant/default.nix
index 242782161d75..3f3fd88580fa 100644
--- a/pkgs/development/tools/vagrant/default.nix
+++ b/pkgs/development/tools/vagrant/default.nix
@@ -1,10 +1,10 @@
-{ stdenv, fetchurl, dpkg, curl, libarchive, openssl, ruby, buildRubyGem, libiconv
+{ stdenv, fetchurl, fetchpatch, dpkg, curl, libarchive, openssl, ruby, buildRubyGem, libiconv
 , libxml2, libxslt, makeWrapper }:
 
 assert stdenv.system == "x86_64-linux" || stdenv.system == "i686-linux";
 
 let
-  version = "1.8.4";
+  version = "1.8.5";
   rake = buildRubyGem {
     inherit ruby;
     gemName = "rake";
@@ -12,22 +12,32 @@ let
     sha256 = "1rn03rqlf1iv6n87a78hkda2yqparhhaivfjpizblmxvlw2hk5r8";
   };
 
-in
-stdenv.mkDerivation rec {
+  sha256 = {
+    "x86_64-linux" = "1na5hxm3ilx268hk68dpgkks1jjh9q7p3ksjx8ssiijq6df47vih";
+    "i686-linux"   = "16psr5s0azpzavizh74085z7wygkfs4ribsfalvbd96phkrkp2wp";
+  }."${stdenv.system}" or (throw "system ${stdenv.system} not supported");
+
+  arch = builtins.replaceStrings ["-linux"] [""] stdenv.system;
+
+in stdenv.mkDerivation rec {
   name = "vagrant-${version}";
   inherit version;
 
-  src =
-    if stdenv.system == "x86_64-linux" then
-      fetchurl {
-        url    = "https://releases.hashicorp.com/vagrant/${version}/vagrant_${version}_x86_64.deb";
-        sha256 = "fd38d8e00e494a617201facb42fc2cac627e5021db15e91c2a041eac6a2d8208";
-      }
-    else
-      fetchurl {
-        url    = "https://releases.hashicorp.com/vagrant/${version}/vagrant_${version}_i686.deb";
-        sha256 = "555351717cacaa8660821df8988cc40a39923b06b698fca6bb90621008aab06f";
-      };
+  src = fetchurl {
+    url = "https://releases.hashicorp.com/vagrant/${version}/vagrant_${version}_${arch}.deb";
+    inherit sha256;
+  };
+
+  # Remove the patchFlags/patches when 1.8.6 is released
+  patchFlags = [
+    "-p1"
+    "-d ./opt/vagrant/embedded/gems/gems/vagrant-${version}"
+  ];
+  patches = (fetchpatch {
+    url = "https://patch-diff.githubusercontent.com/raw/mitchellh/vagrant/pull/7611.diff";
+    name = "fix_incorrect_ssh_keys_permissions.patch";
+    sha256 = "0lqa9xpg79ggp9fc8gzb5lv675ydj2p8l55bx4hs1hf8zz2c1hjf";
+  });
 
   meta = with stdenv.lib; {
     description = "A tool for building complete development environments";