cas-eleves/default.nix

36 lines
749 B
Nix

{
sources ? import ./npins,
pkgs ? import sources.nixpkgs { },
}:
{
devShell = pkgs.mkShell {
name = "cas-eleves.dev";
packages = [
# Python 3.12 is required to have the correct SSL options for connecting with the legacy server
(pkgs.python312.withPackages (ps: [
ps.django
ps.ipython
ps.ldap3
# Local packages
(ps.callPackage ./nix/django-cas-server { })
(ps.callPackage ./nix/loadcredential { })
]))
];
env = {
CREDENTIALS_DIRECTORY = builtins.toString ./.credentials;
CE_DEBUG = true;
CE_STATIC_ROOT = builtins.toString ./.static;
};
shellHook = ''
if [ ! -d .static ]; then
mkdir .static
fi
'';
};
}