Skip to content

Commit

Permalink
bump: update flake lock (#117)
Browse files Browse the repository at this point in the history
* fix: pgadmin-init

in pgadmin-8.2, the command to setup configuration db is `setup-db`

* fix: add grafana overlay
grafana 10.3.3 from upstream nixpkgs doesn’t work in darwin

* chore: free up space in ubuntu-latest

---------

Co-authored-by: shivaraj-bh <[email protected]>
  • Loading branch information
conscious-puppet and shivaraj-bh authored Mar 6, 2024
1 parent 9cdee29 commit e0a1074
Show file tree
Hide file tree
Showing 5 changed files with 51 additions and 13 deletions.
5 changes: 5 additions & 0 deletions .github/workflows/ci.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -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:
Expand Down
2 changes: 1 addition & 1 deletion nix/pgadmin.nix
Original file line number Diff line number Diff line change
Expand Up @@ -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
'';
};
Expand Down
24 changes: 12 additions & 12 deletions test/flake.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions test/overlays/default.nix
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
[
(import ./pgadmin.nix)
(import ./grafana.nix)
]
32 changes: 32 additions & 0 deletions test/overlays/grafana.nix
Original file line number Diff line number Diff line change
@@ -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;
});
});
})

0 comments on commit e0a1074

Please sign in to comment.