Merge pull request #294055 from hercules-ci/hci-hotfix

hci/nix hotfix
This commit is contained in:
Robert Hensing 2024-03-07 17:05:41 +01:00 committed by GitHub
commit 55ee13c6f4
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
14 changed files with 317 additions and 6 deletions

View file

@ -1097,7 +1097,7 @@ self: super: builtins.intersectAttrs super {
hercules-ci-cnix-store = overrideCabal
(old: {
passthru = old.passthru or { } // {
nixPackage = pkgs.nixVersions.nix_2_16;
nixPackage = pkgs.nixVersions.nix_2_19;
};
})
(super.hercules-ci-cnix-store.override {

View file

@ -29,7 +29,7 @@ let
];
extensions = lib.composeManyExtensions ([
nonHackagePackages
(nonHackagePackages { inherit pkgs haskellLib; })
(configurationNix { inherit pkgs haskellLib; })
(configurationCommon { inherit pkgs haskellLib; })
] ++ platformConfigurations ++ [

View file

@ -0,0 +1,66 @@
{ mkDerivation, aeson, async, attoparsec, base, base64-bytestring
, bifunctors, binary, binary-conduit, boost, bytestring, Cabal
, cabal-pkg-config-version-hook, cachix, cachix-api, conduit
, conduit-extra, containers, directory, dlist, exceptions, filepath
, hercules-ci-api, hercules-ci-api-agent, hercules-ci-api-core
, hercules-ci-cnix-expr, hercules-ci-cnix-store, hostname, hspec
, hspec-discover, http-client, http-client-tls, http-conduit, HUnit
, inline-c, inline-c-cpp, katip, lens, lens-aeson, lib
, lifted-async, lifted-base, monad-control, mtl, network
, network-uri, nix, optparse-applicative, process, process-extras
, profunctors, protolude, QuickCheck, safe-exceptions, scientific
, servant, servant-auth-client, servant-client, servant-client-core
, stm, tagged, temporary, text, time, tls, tomland, transformers
, transformers-base, unbounded-delays, unix, unliftio
, unliftio-core, unordered-containers, uuid, vector, websockets
, wuss
}:
mkDerivation {
pname = "hercules-ci-agent";
version = "0.10.1";
sha256 = "a87e1b9ee650c493137d98370df8b3a9d842eea5b3a4c935c34275267ccf94d5";
isLibrary = true;
isExecutable = true;
enableSeparateDataOutput = true;
setupHaskellDepends = [ base Cabal cabal-pkg-config-version-hook ];
libraryHaskellDepends = [
aeson async base binary binary-conduit bytestring conduit
containers directory dlist exceptions filepath
hercules-ci-api-agent hercules-ci-api-core hercules-ci-cnix-expr
hercules-ci-cnix-store katip lens lens-aeson lifted-async
lifted-base monad-control mtl network network-uri process
process-extras protolude safe-exceptions stm tagged temporary text
time tls transformers transformers-base unbounded-delays unix
unliftio unliftio-core uuid vector websockets wuss
];
executableHaskellDepends = [
aeson async attoparsec base base64-bytestring bifunctors binary
binary-conduit bytestring cachix cachix-api conduit conduit-extra
containers directory dlist exceptions filepath hercules-ci-api
hercules-ci-api-agent hercules-ci-api-core hercules-ci-cnix-expr
hercules-ci-cnix-store hostname http-client http-client-tls
http-conduit inline-c inline-c-cpp katip lens lens-aeson
lifted-async lifted-base monad-control mtl network network-uri
optparse-applicative process process-extras profunctors protolude
safe-exceptions scientific servant servant-auth-client
servant-client servant-client-core stm temporary text time tomland
transformers transformers-base unix unliftio unliftio-core
unordered-containers uuid vector websockets wuss
];
executableSystemDepends = [ boost ];
executablePkgconfigDepends = [ nix ];
testHaskellDepends = [
aeson async attoparsec base bifunctors binary binary-conduit
bytestring conduit containers exceptions filepath
hercules-ci-api-agent hercules-ci-api-core hercules-ci-cnix-store
hspec HUnit katip lens lens-aeson lifted-async lifted-base
monad-control mtl process profunctors protolude QuickCheck
safe-exceptions scientific stm tagged temporary text tomland
transformers transformers-base unliftio-core unordered-containers
uuid vector
];
testToolDepends = [ hspec-discover ];
homepage = "https://docs.hercules-ci.com";
description = "Runs Continuous Integration tasks on your machines";
license = lib.licenses.asl20;
}

View file

@ -0,0 +1,27 @@
{ mkDerivation, aeson, base, base64-bytestring-type, bytestring
, containers, cookie, deepseq, exceptions, hashable
, hercules-ci-api-core, hspec, http-api-data, http-media, lens
, lens-aeson, lib, memory, network-uri, profunctors, QuickCheck
, quickcheck-classes, servant, servant-auth, string-conv, swagger2
, text, time, unordered-containers, uuid, vector
}:
mkDerivation {
pname = "hercules-ci-api-agent";
version = "0.5.1.0";
sha256 = "4d98e5a3824b09e3989251787dc0e3c9724011282eec343065c70ba9f1565ee6";
libraryHaskellDepends = [
aeson base base64-bytestring-type bytestring containers cookie
deepseq exceptions hashable hercules-ci-api-core http-api-data
http-media lens lens-aeson memory servant servant-auth string-conv
swagger2 text time unordered-containers uuid vector
];
testHaskellDepends = [
aeson base bytestring containers cookie exceptions hashable
hercules-ci-api-core hspec http-api-data http-media lens memory
network-uri profunctors QuickCheck quickcheck-classes servant
servant-auth string-conv swagger2 text time uuid vector
];
homepage = "https://github.com/hercules-ci/hercules-ci-agent#readme";
description = "API definition for Hercules CI Agent to talk to hercules-ci.com or Hercules CI Enterprise";
license = lib.licenses.asl20;
}

View file

@ -0,0 +1,22 @@
{ mkDerivation, aeson, base, bytestring, containers, cookie
, deepseq, exceptions, hashable, http-api-data, http-media, katip
, lens, lib, lifted-base, memory, monad-control, openapi3
, safe-exceptions, servant, servant-auth, servant-auth-swagger
, servant-openapi3, servant-swagger, servant-swagger-ui-core
, string-conv, swagger2, text, time, uuid
}:
mkDerivation {
pname = "hercules-ci-api-core";
version = "0.1.6.0";
sha256 = "0707c0792223993de583d42144a9e55fb510e6436a67d130d800df23457a1d93";
libraryHaskellDepends = [
aeson base bytestring containers cookie deepseq exceptions hashable
http-api-data http-media katip lens lifted-base memory
monad-control openapi3 safe-exceptions servant servant-auth
servant-auth-swagger servant-openapi3 servant-swagger
servant-swagger-ui-core string-conv swagger2 text time uuid
];
homepage = "https://github.com/hercules-ci/hercules-ci-agent#readme";
description = "Types and convenience modules use across Hercules CI API packages";
license = lib.licenses.asl20;
}

View file

@ -0,0 +1,39 @@
{ mkDerivation, aeson, base, bytestring, containers, cookie
, exceptions, hashable, hercules-ci-api-core, hspec, http-api-data
, http-media, lens, lens-aeson, lib, memory, network-uri, openapi3
, profunctors, protolude, QuickCheck, quickcheck-classes, servant
, servant-auth, servant-auth-swagger, servant-openapi3
, servant-swagger, servant-swagger-ui-core, string-conv, swagger2
, text, time, uuid, vector
}:
mkDerivation {
pname = "hercules-ci-api";
version = "0.8.2.0";
sha256 = "d7e5c0f92c614d0251e11aed56544989c612dd2311dc5b6e7b3fa727c187d256";
isLibrary = true;
isExecutable = true;
libraryHaskellDepends = [
aeson base bytestring containers cookie exceptions hashable
hercules-ci-api-core http-api-data http-media lens lens-aeson
memory network-uri openapi3 profunctors servant servant-auth
servant-auth-swagger servant-openapi3 servant-swagger
servant-swagger-ui-core string-conv swagger2 text time uuid
];
executableHaskellDepends = [
aeson base bytestring containers cookie exceptions hashable
http-api-data http-media lens memory network-uri openapi3
profunctors servant servant-auth servant-auth-swagger
servant-openapi3 servant-swagger servant-swagger-ui-core
string-conv swagger2 text time uuid
];
testHaskellDepends = [
aeson base bytestring containers exceptions hashable
hercules-ci-api-core hspec http-api-data http-media protolude
QuickCheck quickcheck-classes servant servant-auth string-conv text
time uuid vector
];
homepage = "https://github.com/hercules-ci/hercules-ci-agent#readme";
description = "Hercules CI API definition with Servant";
license = lib.licenses.asl20;
mainProgram = "hercules-gen-swagger";
}

View file

@ -0,0 +1,43 @@
{ mkDerivation, aeson, aeson-pretty, async, atomic-write
, attoparsec, base, bytestring, conduit, containers, data-has
, directory, exceptions, filepath, hercules-ci-agent
, hercules-ci-api, hercules-ci-api-agent, hercules-ci-api-core
, hercules-ci-cnix-expr, hercules-ci-cnix-store
, hercules-ci-optparse-applicative, hostname, hspec, http-client
, http-client-tls, http-types, inline-c-cpp, katip, lens
, lens-aeson, lib, lifted-base, monad-control, network-uri, process
, protolude, QuickCheck, retry, rio, safe-exceptions, servant
, servant-auth-client, servant-client, servant-client-core
, servant-conduit, temporary, text, tls, transformers
, transformers-base, unix, unliftio, unliftio-core
, unordered-containers, uuid
}:
mkDerivation {
pname = "hercules-ci-cli";
version = "0.3.7";
sha256 = "bf0a7d9dc26eaff45a1b61f43bef5fb43a8d546b12083f37d450c5b8a7449ec0";
isLibrary = true;
isExecutable = true;
libraryHaskellDepends = [
aeson aeson-pretty async atomic-write attoparsec base bytestring
conduit containers data-has directory exceptions filepath
hercules-ci-agent hercules-ci-api hercules-ci-api-agent
hercules-ci-api-core hercules-ci-cnix-expr hercules-ci-cnix-store
hercules-ci-optparse-applicative hostname http-client
http-client-tls http-types inline-c-cpp katip lens lens-aeson
lifted-base monad-control network-uri process protolude retry rio
safe-exceptions servant servant-auth-client servant-client
servant-client-core servant-conduit temporary text tls transformers
transformers-base unix unliftio unliftio-core unordered-containers
uuid
];
executableHaskellDepends = [ base ];
testHaskellDepends = [
aeson base bytestring containers hspec protolude QuickCheck
unordered-containers
];
homepage = "https://docs.hercules-ci.com";
description = "The hci command for working with Hercules CI";
license = lib.licenses.asl20;
mainProgram = "hci";
}

View file

@ -0,0 +1,30 @@
{ mkDerivation, aeson, base, boost, bytestring, Cabal
, cabal-pkg-config-version-hook, conduit, containers, directory
, exceptions, filepath, hercules-ci-cnix-store, hspec
, hspec-discover, inline-c, inline-c-cpp, lib, nix, process
, protolude, QuickCheck, scientific, temporary, text, unliftio
, unordered-containers, vector
}:
mkDerivation {
pname = "hercules-ci-cnix-expr";
version = "0.3.6.1";
sha256 = "f967e0da57a7aabef256d8843171df51988690036af866537e29ac6ebde76aa5";
enableSeparateDataOutput = true;
setupHaskellDepends = [ base Cabal cabal-pkg-config-version-hook ];
libraryHaskellDepends = [
aeson base bytestring conduit containers directory exceptions
filepath hercules-ci-cnix-store inline-c inline-c-cpp protolude
scientific text unliftio unordered-containers vector
];
librarySystemDepends = [ boost ];
libraryPkgconfigDepends = [ nix ];
testHaskellDepends = [
aeson base bytestring containers filepath hercules-ci-cnix-store
hspec process protolude QuickCheck scientific temporary text
unordered-containers vector
];
testToolDepends = [ hspec-discover ];
homepage = "https://docs.hercules-ci.com";
description = "Bindings for the Nix evaluator";
license = lib.licenses.asl20;
}

View file

@ -0,0 +1,26 @@
{ mkDerivation, base, boost, bytestring, Cabal
, cabal-pkg-config-version-hook, conduit, containers, exceptions
, hspec, hspec-discover, inline-c, inline-c-cpp, lib, nix
, protolude, template-haskell, temporary, text, unix, unliftio-core
, vector
}:
mkDerivation {
pname = "hercules-ci-cnix-store";
version = "0.3.5.0";
sha256 = "395a311514ab5121bf71adc0f67a53b152a091114725fb750c08767a047c7280";
setupHaskellDepends = [ base Cabal cabal-pkg-config-version-hook ];
libraryHaskellDepends = [
base bytestring conduit containers inline-c inline-c-cpp protolude
template-haskell unix unliftio-core vector
];
librarySystemDepends = [ boost ];
libraryPkgconfigDepends = [ nix ];
testHaskellDepends = [
base bytestring containers exceptions hspec inline-c inline-c-cpp
protolude temporary text
];
testToolDepends = [ hspec-discover ];
homepage = "https://docs.hercules-ci.com";
description = "Haskell bindings for Nix's libstore";
license = lib.licenses.asl20;
}

View file

@ -0,0 +1,37 @@
{ mkDerivation, aeson, aeson-pretty, base, base-compat-batteries
, bytestring, Cabal, cabal-doctest, containers, cookie, doctest
, generics-sop, Glob, hashable, hspec, hspec-discover, http-media
, HUnit, insert-ordered-containers, lens, lib, mtl, optics-core
, optics-th, QuickCheck, quickcheck-instances, scientific
, template-haskell, text, time, transformers, unordered-containers
, utf8-string, uuid-types, vector
}:
mkDerivation {
pname = "openapi3";
version = "3.2.4";
sha256 = "dbcb90464b4712a03c37fa3fcaca3a6784ace2794d85730a8a8c5d9b3ea14ba0";
revision = "1";
editedCabalFile = "08ikd506fxz3pllg5w8lx9yn9qfqlx9il9xwzz7s17yxn5k3xmnk";
isLibrary = true;
isExecutable = true;
setupHaskellDepends = [ base Cabal cabal-doctest ];
libraryHaskellDepends = [
aeson aeson-pretty base base-compat-batteries bytestring containers
cookie generics-sop hashable http-media insert-ordered-containers
lens mtl optics-core optics-th QuickCheck scientific
template-haskell text time transformers unordered-containers
uuid-types vector
];
executableHaskellDepends = [ aeson base lens text ];
testHaskellDepends = [
aeson base base-compat-batteries bytestring containers doctest Glob
hashable hspec HUnit insert-ordered-containers lens mtl QuickCheck
quickcheck-instances template-haskell text time
unordered-containers utf8-string vector
];
testToolDepends = [ hspec-discover ];
homepage = "https://github.com/biocad/openapi3";
description = "OpenAPI 3.0 data model";
license = lib.licenses.bsd3;
mainProgram = "example";
}

View file

@ -0,0 +1,10 @@
#!/usr/bin/env bash
cd "$(dirname "${BASH_SOURCE[0]}")"
cabal2nix cabal://hercules-ci-agent >hercules-ci-agent.nix
cabal2nix cabal://hercules-ci-api >hercules-ci-api.nix
cabal2nix cabal://hercules-ci-api-agent >hercules-ci-api-agent.nix
cabal2nix cabal://hercules-ci-api-core >hercules-ci-api-core.nix
cabal2nix cabal://hercules-ci-cli >hercules-ci-cli.nix
cabal2nix cabal://hercules-ci-cnix-expr >hercules-ci-cnix-expr.nix
cabal2nix cabal://hercules-ci-cnix-store >hercules-ci-cnix-store.nix
cabal2nix cabal://openapi3 >openapi3.nix

View file

@ -1,3 +1,5 @@
{ pkgs, haskellLib }:
# EXTRA HASKELL PACKAGES NOT ON HACKAGE
#
# This file should only contain packages that are not in ./hackage-packages.nix.
@ -39,4 +41,13 @@ self: super: {
# cabal2nix --maintainer roberth https://github.com/hercules-ci/optparse-applicative.git > pkgs/development/misc/haskell/hercules-ci-optparse-applicative.nix
hercules-ci-optparse-applicative = self.callPackage ../misc/haskell/hercules-ci-optparse-applicative.nix {};
# Hotfixes
hercules-ci-agent = self.callPackage ./hotfixes/hercules-ci-agent.nix {};
hercules-ci-api = self.callPackage ./hotfixes/hercules-ci-api.nix {};
hercules-ci-api-agent = self.callPackage ./hotfixes/hercules-ci-api-agent.nix {};
hercules-ci-api-core = self.callPackage ./hotfixes/hercules-ci-api-core.nix {};
hercules-ci-cli = self.callPackage ./hotfixes/hercules-ci-cli.nix {};
hercules-ci-cnix-expr = self.callPackage ./hotfixes/hercules-ci-cnix-expr.nix {};
hercules-ci-cnix-store = self.callPackage ./hotfixes/hercules-ci-cnix-store.nix {};
openapi3 = self.callPackage ./hotfixes/openapi3.nix {};
}

View file

@ -1,8 +1,8 @@
{ haskell, haskellPackages, lib, makeWrapper, runc, stdenv, emptyDirectory }:
{ crun, haskell, haskellPackages, lib, makeWrapper, stdenv, emptyDirectory }:
let
inherit (haskell.lib.compose) overrideCabal addBuildTools justStaticExecutables appendConfigureFlags;
inherit (lib) makeBinPath;
bundledBins = lib.optional stdenv.isLinux runc;
bundledBins = lib.optional stdenv.isLinux crun;
overrides = old: {
hercules-ci-agent =

View file

@ -1,4 +1,5 @@
{
crun,
git,
gnutar,
gzip,
@ -8,14 +9,13 @@
makeBinaryWrapper,
nixos,
openssh,
runc,
stdenv,
testers,
}:
let
inherit (haskell.lib.compose) overrideCabal addBuildTools justStaticExecutables;
inherit (lib) makeBinPath;
bundledBins = [ gnutar gzip git openssh ] ++ lib.optional stdenv.isLinux runc;
bundledBins = [ gnutar gzip git openssh ] ++ lib.optional stdenv.isLinux crun;
pkg =
# justStaticExecutables is needed due to https://github.com/NixOS/nix/issues/2990