Skip to content

Commit

Permalink
Merge pull request #59779 from AmineChikhaoui/cherrypick-nixops-1.7
Browse files Browse the repository at this point in the history
cherry pick nixops update to 1.7
  • Loading branch information
grahamc committed Apr 17, 2019
2 parents 820226e + 5e094b9 commit fc27713
Show file tree
Hide file tree
Showing 5 changed files with 42 additions and 29 deletions.
21 changes: 3 additions & 18 deletions pkgs/tools/package-management/nixops/default.nix
@@ -1,24 +1,9 @@
{ callPackage, newScope, pkgs, fetchurl }:

callPackage ./generic.nix (rec {
version = "1.6.1";
version = "1.7";
src = fetchurl {
url = "http://nixos.org/releases/nixops/nixops-${version}/nixops-${version}.tar.bz2";
sha256 = "0lfx5fhyg3z6725ydsk0ibg5qqzp5s0x9nbdww02k8s307axiah3";
};
# nixops is incompatible with the most recent versions of listed
# azure-mgmt-* packages, therefore we are pinning them to
# package-private versions, so that they don't get trampled by
# updates.
# see
# https://github.com/NixOS/nixops/issues/1065
python2Packages = pkgs.python2Packages.override {
overrides = (self: super: let callPackage = newScope self; in {
azure-mgmt-compute = callPackage ./azure-mgmt-compute { };
azure-mgmt-network = callPackage ./azure-mgmt-network { };
azure-mgmt-nspkg = callPackage ./azure-mgmt-nspkg { };
azure-mgmt-resource = callPackage ./azure-mgmt-resource { };
azure-mgmt-storage = callPackage ./azure-mgmt-storage { };
});
url = "https://nixos.org/releases/nixops/nixops-${version}/nixops-${version}.tar.bz2";
sha256 = "091c0b5bca57d4aa20be20e826ec161efe3aec9c788fbbcf3806a734a517f0f3";
};
})
11 changes: 3 additions & 8 deletions pkgs/tools/package-management/nixops/generic.nix
@@ -1,4 +1,4 @@
{ lib, python2Packages, libxslt, docbook_xsl_ns, openssh, cacert
{ lib, python2Packages, libxslt, docbook_xsl_ns, openssh, cacert, nixopsAzurePackages ? []
# version args
, src, version
}:
Expand All @@ -15,19 +15,14 @@ python2Packages.buildPythonApplication {
boto3
hetzner
libcloud
azure-storage
azure-mgmt-compute
azure-mgmt-network
azure-mgmt-resource
azure-mgmt-storage
adal
# Go back to sqlite once Python 2.7.13 is released
pysqlite
datadog
digital-ocean
libvirt
typing
];
] ++ nixopsAzurePackages;

checkPhase =
# Ensure, that there are no (python) import errors
Expand All @@ -52,7 +47,7 @@ python2Packages.buildPythonApplication {
meta = {
homepage = https://github.com/NixOS/nixops;
description = "NixOS cloud provisioning and deployment tool";
maintainers = with lib.maintainers; [ eelco rob domenkozar ];
maintainers = with lib.maintainers; [ aminechikhaoui eelco rob domenkozar ];
platforms = lib.platforms.unix;
license = lib.licenses.lgpl3;
};
Expand Down
31 changes: 31 additions & 0 deletions pkgs/tools/package-management/nixops/nixops-v1_6_1.nix
@@ -0,0 +1,31 @@
{ callPackage, newScope, pkgs, fetchurl }:

callPackage ./generic.nix (rec {
version = "1.6.1";
src = fetchurl {
url = "http://nixos.org/releases/nixops/nixops-${version}/nixops-${version}.tar.bz2";
sha256 = "0lfx5fhyg3z6725ydsk0ibg5qqzp5s0x9nbdww02k8s307axiah3";
};
nixopsAzurePackages = with python2Packages; [
azure-storage
azure-mgmt-compute
azure-mgmt-network
azure-mgmt-resource
azure-mgmt-storage
];
# nixops is incompatible with the most recent versions of listed
# azure-mgmt-* packages, therefore we are pinning them to
# package-private versions, so that they don't get trampled by
# updates.
# see
# https://github.com/NixOS/nixops/issues/1065
python2Packages = pkgs.python2Packages.override {
overrides = (self: super: let callPackage = newScope self; in {
azure-mgmt-compute = callPackage ./azure-mgmt-compute { };
azure-mgmt-network = callPackage ./azure-mgmt-network { };
azure-mgmt-nspkg = callPackage ./azure-mgmt-nspkg { };
azure-mgmt-resource = callPackage ./azure-mgmt-resource { };
azure-mgmt-storage = callPackage ./azure-mgmt-storage { };
});
};
})
6 changes: 3 additions & 3 deletions pkgs/tools/package-management/nixops/unstable.nix
Expand Up @@ -5,9 +5,9 @@
# Then copy the URL to the tarball.

callPackage ./generic.nix (rec {
version = "1.6.1pre2728_8ed39f9";
version = "1.7pre2764_932bf43";
src = fetchurl {
url = "https://hydra.nixos.org/build/88329589/download/2/nixops-${version}.tar.bz2";
sha256 = "1ppnhqmsbiijm6r77h86abv3fjny5iq35yvj207s520kjwzaj7kc";
url = "https://hydra.nixos.org/build/92372343/download/2/nixops-${version}.tar.bz2";
sha256 = "f35bf81bf2805473ea54248d0ee92d163d00a1992f3f75d17e8cf430db1f9919";
};
})
2 changes: 2 additions & 0 deletions pkgs/top-level/all-packages.nix
Expand Up @@ -22549,6 +22549,8 @@ in

nixops = callPackage ../tools/package-management/nixops { };

nixops_1_6_1 = callPackage ../tools/package-management/nixops/nixops-v1_6_1.nix {};

nixopsUnstable = lowPrio (callPackage ../tools/package-management/nixops/unstable.nix { });

nixops-dns = callPackage ../tools/package-management/nixops/nixops-dns.nix { };
Expand Down

0 comments on commit fc27713

Please sign in to comment.