diff --git a/.github/workflows/ci.yaml b/.github/workflows/ci.yaml index 0b38148..2bd5891 100644 --- a/.github/workflows/ci.yaml +++ b/.github/workflows/ci.yaml @@ -11,6 +11,11 @@ jobs: matrix: os: [ubuntu-latest, macos-latest, macos-14] steps: + - name: Free up space + if: matrix.os == 'ubuntu-latest' + run: | + sudo rm -rf "/usr/local/share/boost" + sudo rm -rf "$AGENT_TOOLSDIRECTORY" - uses: actions/checkout@v3 - uses: DeterminateSystems/nix-installer-action@main with: diff --git a/nix/pgadmin.nix b/nix/pgadmin.nix index 473528d..fdf9da8 100644 --- a/nix/pgadmin.nix +++ b/nix/pgadmin.nix @@ -118,7 +118,7 @@ in ${config.package}/bin/.pgadmin4-setup-wrapped setup else # pgadmin-8.2 has .pgadmin4-cli-wrapped - ${config.package}/bin/.pgadmin4-cli-wrapped setup + ${config.package}/bin/.pgadmin4-cli-wrapped setup-db fi ''; }; diff --git a/test/flake.lock b/test/flake.lock index a12fbd6..48a02be 100644 --- a/test/flake.lock +++ b/test/flake.lock @@ -5,11 +5,11 @@ "nixpkgs-lib": "nixpkgs-lib" }, "locked": { - "lastModified": 1685662779, - "narHash": "sha256-cKDDciXGpMEjP1n6HlzKinN0H+oLmNpgeCTzYnsA2po=", + "lastModified": 1709336216, + "narHash": "sha256-Dt/wOWeW6Sqm11Yh+2+t0dfEWxoMxGBvv3JpIocFl9E=", "owner": "hercules-ci", "repo": "flake-parts", - "rev": "71fb97f0d875fd4de4994dfb849f2c75e17eb6c3", + "rev": "f7b3c975cf067e56e7cda6cb098ebe3fb4d74ca2", "type": "github" }, "original": { @@ -20,11 +20,11 @@ }, "nixpkgs": { "locked": { - "lastModified": 1696630667, - "narHash": "sha256-kO67pYOeT/6m9BnPO+zNHWnC4eGiW87gIAJ+e8f3gwU=", + "lastModified": 1709294055, + "narHash": "sha256-7EECkQYoNKJZOf2+miJdrMpxpvsn/qZFwIhUI3fQpLs=", "owner": "nixos", "repo": "nixpkgs", - "rev": "b604023e0a5549b65da3040a07d2beb29ac9fc63", + "rev": "ec869190b56a1b4677d24a8bdbcfe80ccea2ece6", "type": "github" }, "original": { @@ -37,11 +37,11 @@ "nixpkgs-lib": { "locked": { "dir": "lib", - "lastModified": 1685564631, - "narHash": "sha256-8ywr3AkblY4++3lIVxmrWZFzac7+f32ZEhH/A8pNscI=", + "lastModified": 1709237383, + "narHash": "sha256-cy6ArO4k5qTx+l5o+0mL9f5fa86tYUX3ozE1S+Txlds=", "owner": "NixOS", "repo": "nixpkgs", - "rev": "4f53efe34b3a8877ac923b9350c874e3dcd5dc0a", + "rev": "1536926ef5621b09bba54035ae2bb6d806d72ac8", "type": "github" }, "original": { @@ -54,11 +54,11 @@ }, "process-compose-flake": { "locked": { - "lastModified": 1708620954, - "narHash": "sha256-kFgAt2kJZ9JleWgo+cFULoya31o9EiukNg1H4G0+KnM=", + "lastModified": 1708624100, + "narHash": "sha256-zZPheCD9JGg2EtK4A9BsIdyl8447egOow4fjIfHFHRg=", "owner": "Platonic-Systems", "repo": "process-compose-flake", - "rev": "dded78fff52b069bd55607b15b49739e8310efb3", + "rev": "44d260ddba5a51570dee54d5cd4d8984edaf98c2", "type": "github" }, "original": { diff --git a/test/overlays/default.nix b/test/overlays/default.nix index 8318f99..2900e8c 100644 --- a/test/overlays/default.nix +++ b/test/overlays/default.nix @@ -1,3 +1,4 @@ [ (import ./pgadmin.nix) + (import ./grafana.nix) ] diff --git a/test/overlays/grafana.nix b/test/overlays/grafana.nix new file mode 100644 index 0000000..8f4ae73 --- /dev/null +++ b/test/overlays/grafana.nix @@ -0,0 +1,32 @@ +(final: prev: { + grafana = (prev.callPackage "${prev.path}/pkgs/servers/monitoring/grafana" { + buildGoModule = args: prev.buildGoModule (args // { + + vendorHash = "sha256-Ig7Vj3HzMVOjT6Tn8aS4W000uKGoPOCFh2yIfyEWn78="; + + proxyVendor = true; + + offlineCache = args.offlineCache.overrideAttrs (oa: { + buildPhase = final.lib.replaceStrings + [ "yarn config set --json supportedArchitectures.os '[ \"linux\" ]'" ] + [ "yarn config set --json supportedArchitectures.os '[ \"linux\", \"darwin\" ]'" ] + oa.buildPhase; + + outputHash = + if final.stdenv.isLinux then + "sha256-IlNe89T6cfXGy1WY73Yd+wg1bt9UuBCkKSDkrazybQM=" + else + "sha256-pqInPfZEg2tcp8BXg1nnMddRZ1yyZ6KQa2flWd4IZSU="; + }); + + # exclude the package instead of `rm pkg/util/xorm/go.{mod,sum}` + # turns out, only removing the files is not enough, fails with: + # > pkg/services/sqlstore/migrator/dialect.go:9:2: module ./pkg/util/xorm: reading pkg/util/xorm/go.mod: open /build/source/pkg/util/xorm/go.mod: no such file or directory + + # both excluding and removing (`go.mod`) is also not an option because excludedPackages expects a `go.mod` + excludedPackages = args.excludedPackages ++ [ "xorm" ]; + + postConfigure = final.lib.replaceStrings [ "rm pkg/util/xorm/go.{mod,sum}" ] [ "" ] args.postConfigure; + }); + }); +})