Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
22 changes: 20 additions & 2 deletions nix/shells.nix
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,26 @@
}:
{
devShells = {
default = pkgs.mkShell { inputsFrom = [ config.packages.default ]; };
postgres = pkgs.mkShell { inputsFrom = [ config.packages.cln-postgres ]; };
default = pkgs.mkShell {
inputsFrom = [ config.packages.default ];
buildInputs = [
pkgs.openssl
pkgs.uv
];
# On Linux, uv uses nixpkgs' Python: the Python uv downloads expects
# an FHS dynamic loader, so it doesn't run on NixOS.
# LD_LIBRARY_PATH fixes the following error when running uv pytest tests/:
# ImportError: libstdc++.so.6: cannot open shared object file: No such file or directory
shellHook = pkgs.lib.optionalString pkgs.stdenv.isLinux ''
export UV_PYTHON=${pkgs.python3}/bin/python3
export UV_PYTHON_DOWNLOADS=never
export LD_LIBRARY_PATH="${pkgs.stdenv.cc.cc.lib}/lib''${LD_LIBRARY_PATH:+:}$LD_LIBRARY_PATH"
'';
};
postgres = pkgs.mkShell {
inputsFrom = [ config.packages.cln-postgres ];
buildInputs = [ pkgs.openssl ];
};
rust = pkgs.craneLib.devShell {
checks = {
inherit (self.checks.${system}) rust;
Expand Down
Loading