2024-11-25 15:59:32 +01:00
|
|
|
{
|
|
|
|
pkgs,
|
|
|
|
sources,
|
|
|
|
config,
|
|
|
|
...
|
|
|
|
}:
|
2024-10-22 14:19:58 +02:00
|
|
|
|
|
|
|
let
|
|
|
|
nix-pkgs = import sources.nix-pkgs { inherit pkgs; };
|
|
|
|
in
|
|
|
|
|
|
|
|
{
|
|
|
|
services.django-apps.sites.wikiens = {
|
|
|
|
source = "https://git.dgnum.eu/DGNum/wiki-eleves";
|
|
|
|
branch = "main";
|
2024-11-25 15:59:32 +01:00
|
|
|
domain = "wiki.eleves.ens.fr";
|
2024-10-22 14:19:58 +02:00
|
|
|
|
|
|
|
nginx = {
|
|
|
|
enableACME = true;
|
|
|
|
forceSSL = true;
|
|
|
|
};
|
|
|
|
|
2024-11-25 15:59:32 +01:00
|
|
|
webHookSecret = config.age.secrets."webhook-wikiens_token".path;
|
2024-10-22 14:19:58 +02:00
|
|
|
|
|
|
|
python = pkgs.python3.override {
|
2024-11-23 11:33:56 +01:00
|
|
|
packageOverrides = _: _: {
|
|
|
|
inherit (nix-pkgs)
|
|
|
|
django-allauth
|
|
|
|
django-allauth-ens
|
|
|
|
django-wiki
|
|
|
|
loadcredential
|
|
|
|
;
|
|
|
|
};
|
2024-10-22 14:19:58 +02:00
|
|
|
};
|
|
|
|
|
2024-11-23 11:33:56 +01:00
|
|
|
dependencies =
|
|
|
|
ps:
|
|
|
|
[
|
|
|
|
ps.django
|
|
|
|
ps.django-allauth-ens
|
|
|
|
ps.django-wiki
|
|
|
|
ps.loadcredential
|
|
|
|
ps.tinycss2
|
|
|
|
]
|
|
|
|
++ ps.django-allauth.optional-dependencies.socialaccount;
|
2024-10-22 14:19:58 +02:00
|
|
|
|
|
|
|
credentials = {
|
2024-11-25 15:59:32 +01:00
|
|
|
SECRET_KEY = config.age.secrets."dj_wikiens-secret_key_file".path;
|
2024-10-22 14:19:58 +02:00
|
|
|
};
|
|
|
|
|
|
|
|
environment = {
|
2024-11-25 15:59:32 +01:00
|
|
|
WIKIENS_ALLOWED_HOSTS = [ "wiki.eleves.ens.fr" ];
|
2024-10-22 14:19:58 +02:00
|
|
|
};
|
|
|
|
};
|
|
|
|
}
|