inputs: bump nixpkgs, frappix. migrate inventree
This commit is contained in:
Generated
+9
-9
@@ -294,11 +294,11 @@
|
|||||||
"std": "std"
|
"std": "std"
|
||||||
},
|
},
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1779175997,
|
"lastModified": 1780907315,
|
||||||
"narHash": "sha256-Ps/4s3jwaZdLVEpO+1cRs54VbPbgMeXJUqa4CWSPJSY=",
|
"narHash": "sha256-MR859lKVKeItsC5wnd1oniBar2lBTA+FJ7Bx4xN1Wpk=",
|
||||||
"owner": "kurogeek",
|
"owner": "kurogeek",
|
||||||
"repo": "frappix",
|
"repo": "frappix",
|
||||||
"rev": "0f1b4bcfb8c3b976e808a57e491d10857a1a45ac",
|
"rev": "9c2bc4152bce6d91305bcf0563a8a715860c405d",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
@@ -522,11 +522,11 @@
|
|||||||
]
|
]
|
||||||
},
|
},
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1714086354,
|
"lastModified": 1746801636,
|
||||||
"narHash": "sha256-yKVQMxL9p7zCWUhnGhDzRVT8sDgHoI3V595lBK0C2YA=",
|
"narHash": "sha256-dlcKfIXp/eqFHzFm+DzseXAWWlpVwyk9cTvCKGtVKkw=",
|
||||||
"owner": "nix-community",
|
"owner": "nix-community",
|
||||||
"repo": "nixago",
|
"repo": "nixago",
|
||||||
"rev": "5133633e9fe6b144c8e00e3b212cdbd5a173b63d",
|
"rev": "8cc33f973ab3a891d8a41391e73ef451a783960b",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
@@ -552,11 +552,11 @@
|
|||||||
},
|
},
|
||||||
"nixpkgs_2": {
|
"nixpkgs_2": {
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1778458615,
|
"lastModified": 1781359544,
|
||||||
"narHash": "sha256-cY07EsdhBJ8tFXPzDYevgqxRev9ZLxFonuq9wmq5kwg=",
|
"narHash": "sha256-iUuzKQcyXvopYDDzFpMK5eQKP3WIJExYny2kJtbgUcE=",
|
||||||
"owner": "nixos",
|
"owner": "nixos",
|
||||||
"repo": "nixpkgs",
|
"repo": "nixpkgs",
|
||||||
"rev": "c6e5ca3c836a5f4dd9af9f2c1fc1c38f0fac988a",
|
"rev": "9f11f828c213641c2369a9f1fa31fe31557e3156",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
|
|||||||
@@ -56,7 +56,6 @@
|
|||||||
./shell.nix
|
./shell.nix
|
||||||
|
|
||||||
./overlays
|
./overlays
|
||||||
./modules/nixos
|
|
||||||
./machines
|
./machines
|
||||||
./routers
|
./routers
|
||||||
./inventories
|
./inventories
|
||||||
|
|||||||
@@ -9,13 +9,6 @@ let
|
|||||||
in
|
in
|
||||||
{
|
{
|
||||||
clan.core.settings.machine.description = "VM machine that host Inventree system for Poy";
|
clan.core.settings.machine.description = "VM machine that host Inventree system for Poy";
|
||||||
imports = [
|
|
||||||
inputs.self.nixosModules.inventree
|
|
||||||
];
|
|
||||||
|
|
||||||
nixpkgs.overlays = [
|
|
||||||
inputs.self.overlays.packagesOverlay
|
|
||||||
];
|
|
||||||
|
|
||||||
nixpkgs.hostPlatform = {
|
nixpkgs.hostPlatform = {
|
||||||
system = "x86_64-linux";
|
system = "x86_64-linux";
|
||||||
@@ -82,19 +75,12 @@ in
|
|||||||
|
|
||||||
services.inventree = {
|
services.inventree = {
|
||||||
enable = true;
|
enable = true;
|
||||||
hostName = "${domain}";
|
inherit domain;
|
||||||
config.site_url = "https://${config.services.inventree.hostName}";
|
|
||||||
secretKeyFile = config.clan.core.vars.generators.inventree.files.secret-key.path;
|
secretKeyFile = config.clan.core.vars.generators.inventree.files.secret-key.path;
|
||||||
config.oidc_private_key_file = config.clan.core.vars.generators.inventree.files.oidc-key.path;
|
adminPasswordFile = config.clan.core.vars.generators.inventree.files.admin-password.path;
|
||||||
config.adminPasswordFile = config.clan.core.vars.generators.inventree.files.admin-password.path;
|
settings.INVENTREE_SITE_URL = "https://${domain}";
|
||||||
};
|
};
|
||||||
|
|
||||||
# services.nginx.virtualHosts."${domain}" = {
|
|
||||||
# forceSSL = true;
|
|
||||||
# sslCertificate = config.clan.core.vars.generators.nginx.files.sslCert.path;
|
|
||||||
# sslCertificateKey = config.clan.core.vars.generators.nginx.files.sslKey.path;
|
|
||||||
# };
|
|
||||||
|
|
||||||
system.stateVersion = "25.11";
|
system.stateVersion = "25.11";
|
||||||
clan.core.sops.defaultGroups = [ "admins" ];
|
clan.core.sops.defaultGroups = [ "admins" ];
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -9,13 +9,6 @@ let
|
|||||||
in
|
in
|
||||||
{
|
{
|
||||||
clan.core.settings.machine.description = "VM machine that host Inventree system for Glom";
|
clan.core.settings.machine.description = "VM machine that host Inventree system for Glom";
|
||||||
imports = [
|
|
||||||
inputs.self.nixosModules.inventree
|
|
||||||
];
|
|
||||||
|
|
||||||
nixpkgs.overlays = [
|
|
||||||
inputs.self.overlays.packagesOverlay
|
|
||||||
];
|
|
||||||
|
|
||||||
nixpkgs.hostPlatform = {
|
nixpkgs.hostPlatform = {
|
||||||
system = "x86_64-linux";
|
system = "x86_64-linux";
|
||||||
@@ -82,19 +75,12 @@ in
|
|||||||
|
|
||||||
services.inventree = {
|
services.inventree = {
|
||||||
enable = true;
|
enable = true;
|
||||||
hostName = "${domain}";
|
inherit domain;
|
||||||
config.site_url = "https://${config.services.inventree.hostName}";
|
|
||||||
secretKeyFile = config.clan.core.vars.generators.inventree.files.secret-key.path;
|
secretKeyFile = config.clan.core.vars.generators.inventree.files.secret-key.path;
|
||||||
config.oidc_private_key_file = config.clan.core.vars.generators.inventree.files.oidc-key.path;
|
adminPasswordFile = config.clan.core.vars.generators.inventree.files.admin-password.path;
|
||||||
config.adminPasswordFile = config.clan.core.vars.generators.inventree.files.admin-password.path;
|
settings.INVENTREE_SITE_URL = "https://${domain}";
|
||||||
};
|
};
|
||||||
|
|
||||||
# services.nginx.virtualHosts."${domain}" = {
|
|
||||||
# forceSSL = true;
|
|
||||||
# sslCertificate = config.clan.core.vars.generators.nginx.files.sslCert.path;
|
|
||||||
# sslCertificateKey = config.clan.core.vars.generators.nginx.files.sslKey.path;
|
|
||||||
# };
|
|
||||||
|
|
||||||
system.stateVersion = "25.11";
|
system.stateVersion = "25.11";
|
||||||
clan.core.sops.defaultGroups = [ "admins" ];
|
clan.core.sops.defaultGroups = [ "admins" ];
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,5 +0,0 @@
|
|||||||
{
|
|
||||||
flake.nixosModules = {
|
|
||||||
inventree = import ../nixos/inventree;
|
|
||||||
};
|
|
||||||
}
|
|
||||||
@@ -1,334 +0,0 @@
|
|||||||
{
|
|
||||||
lib,
|
|
||||||
config,
|
|
||||||
pkgs,
|
|
||||||
...
|
|
||||||
}:
|
|
||||||
let
|
|
||||||
inherit (lib)
|
|
||||||
mkEnableOption
|
|
||||||
mkOption
|
|
||||||
types
|
|
||||||
mkIf
|
|
||||||
;
|
|
||||||
|
|
||||||
configFormat = pkgs.formats.json { };
|
|
||||||
cfg = config.services.inventree;
|
|
||||||
pkg = cfg.package;
|
|
||||||
configFile = "${cfg.dataDir}/config.json";
|
|
||||||
|
|
||||||
env = {
|
|
||||||
INVENTREE_CONFIG_FILE = configFile;
|
|
||||||
INVENTREE_SECRET_KEY_FILE = cfg.secretKeyFile;
|
|
||||||
INVENTREE_AUTO_UPDATE = "1";
|
|
||||||
INVENTREE_PLUGINS_ENABLED = "1";
|
|
||||||
INVENTREE_PLUGIN_NOINSTALL = "0";
|
|
||||||
INVENTREE_STATIC_ROOT = cfg.config.static_root;
|
|
||||||
INVENTREE_MEDIA_ROOT = cfg.config.media_root;
|
|
||||||
INVENTREE_BACKUP_DIR = cfg.config.backup_dir;
|
|
||||||
INVENTREE_OIDC_PRIVATE_KEY_FILE = cfg.config.oidc_private_key_file;
|
|
||||||
INVENTREE_DB_ENGINE = cfg.config.database.ENGINE;
|
|
||||||
INVENTREE_DB_NAME = cfg.config.database.NAME;
|
|
||||||
INVENTREE_DB_HOST = cfg.config.database.HOST;
|
|
||||||
INVENTREE_DB_USER = "inventree";
|
|
||||||
INVENTREE_ADMIN_USER = cfg.config.adminUser;
|
|
||||||
INVENTREE_ADMIN_PASSWORD_FILE = cfg.config.adminPasswordFile;
|
|
||||||
INVENTREE_USE_X_FORWARDED_HOST = "1";
|
|
||||||
INVENTREE_CORS_ORIGIN_ALLOW_ALL = "1";
|
|
||||||
INVENTREE_FRONTEND_SETTINGS = ''{"mobile_mode":"allow-always"}'';
|
|
||||||
|
|
||||||
INVENTREE_SITE_URL = cfg.config.site_url;
|
|
||||||
|
|
||||||
PYTHONPATH = pkg.pythonPath;
|
|
||||||
};
|
|
||||||
|
|
||||||
inventree-invoke = pkgs.writeShellApplication {
|
|
||||||
name = "inventree-invoke";
|
|
||||||
text = ''
|
|
||||||
export INVENTREE_CONFIG_FILE=${configFile}
|
|
||||||
export INVENTREE_SECRET_KEY_FILE=${cfg.secretKeyFile}
|
|
||||||
export PYTHONPATH=${pkg.pythonPath}
|
|
||||||
|
|
||||||
exec -a "$0" ${pkgs.python3Packages.invoke}/bin/invoke -r ${cfg.package}/opt/inventree "$@"
|
|
||||||
'';
|
|
||||||
};
|
|
||||||
in
|
|
||||||
{
|
|
||||||
options.services.inventree = {
|
|
||||||
enable = mkEnableOption "InvenTree parts manager";
|
|
||||||
|
|
||||||
package = lib.mkOption {
|
|
||||||
type = types.package;
|
|
||||||
default = pkgs.inventree;
|
|
||||||
description = ''
|
|
||||||
InvenTree package to use
|
|
||||||
'';
|
|
||||||
};
|
|
||||||
|
|
||||||
hostName = mkOption {
|
|
||||||
type = types.str;
|
|
||||||
description = "FQDN for the InvenTree instance.";
|
|
||||||
};
|
|
||||||
|
|
||||||
dataDir = mkOption {
|
|
||||||
type = types.path;
|
|
||||||
default = "/var/lib/inventree";
|
|
||||||
example = "/var/lib/inventree";
|
|
||||||
description = ''
|
|
||||||
The default path for all inventree data.
|
|
||||||
'';
|
|
||||||
};
|
|
||||||
|
|
||||||
secretKeyFile = mkOption {
|
|
||||||
type = types.path;
|
|
||||||
default = "${cfg.dataDir}/secret_key.txt";
|
|
||||||
description = ''
|
|
||||||
Path to a file containing the secret key
|
|
||||||
'';
|
|
||||||
};
|
|
||||||
|
|
||||||
config = mkOption {
|
|
||||||
type = types.submodule ({
|
|
||||||
freeformType = configFormat.type;
|
|
||||||
options = {
|
|
||||||
adminUser = mkOption {
|
|
||||||
type = types.str;
|
|
||||||
default = "admin";
|
|
||||||
};
|
|
||||||
adminPasswordFile = mkOption {
|
|
||||||
type = types.path;
|
|
||||||
description = "Path to password file for user `admin`";
|
|
||||||
};
|
|
||||||
site_url = mkOption {
|
|
||||||
type = types.str;
|
|
||||||
default = "https://${cfg.hostName}";
|
|
||||||
};
|
|
||||||
static_root = mkOption {
|
|
||||||
type = types.path;
|
|
||||||
default = "${cfg.dataDir}/static";
|
|
||||||
description = ''
|
|
||||||
Static file storage
|
|
||||||
'';
|
|
||||||
};
|
|
||||||
media_root = mkOption {
|
|
||||||
type = types.path;
|
|
||||||
default = "${cfg.dataDir}/media_root";
|
|
||||||
description = "Media root directory";
|
|
||||||
};
|
|
||||||
backup_dir = mkOption {
|
|
||||||
type = types.path;
|
|
||||||
default = "${cfg.dataDir}/backups";
|
|
||||||
description = "Backup directory";
|
|
||||||
};
|
|
||||||
oidc_private_key_file = mkOption {
|
|
||||||
type = types.path;
|
|
||||||
default = "${cfg.dataDir}/oidc.key";
|
|
||||||
};
|
|
||||||
};
|
|
||||||
});
|
|
||||||
default = { };
|
|
||||||
description = ''
|
|
||||||
Config options, see https://docs.inventree.org/en/stable/start/config/
|
|
||||||
for details
|
|
||||||
'';
|
|
||||||
};
|
|
||||||
|
|
||||||
serverStartTimeout = mkOption {
|
|
||||||
type = types.str;
|
|
||||||
default = "10min";
|
|
||||||
description = ''
|
|
||||||
TimeoutStartSec for the server systemd service.
|
|
||||||
See https://www.freedesktop.org/software/systemd/man/latest/systemd.service.html#TimeoutStartSec=
|
|
||||||
for more details
|
|
||||||
'';
|
|
||||||
};
|
|
||||||
|
|
||||||
serverStopTimeout = mkOption {
|
|
||||||
type = types.str;
|
|
||||||
default = "5min";
|
|
||||||
description = ''
|
|
||||||
TimeoutStopSec for the server systemd service.
|
|
||||||
See https://www.freedesktop.org/software/systemd/man/latest/systemd.service.html#TimeoutStopSec=
|
|
||||||
for more details
|
|
||||||
'';
|
|
||||||
};
|
|
||||||
|
|
||||||
};
|
|
||||||
|
|
||||||
config = mkIf cfg.enable {
|
|
||||||
environment.systemPackages = [ inventree-invoke ];
|
|
||||||
|
|
||||||
systemd.tmpfiles.rules = (
|
|
||||||
map (dir: "d ${dir} 0755 inventree inventree") [
|
|
||||||
"${cfg.dataDir}"
|
|
||||||
"${cfg.dataDir}/static"
|
|
||||||
"${cfg.dataDir}/media_root"
|
|
||||||
"${cfg.dataDir}/backups"
|
|
||||||
]
|
|
||||||
);
|
|
||||||
|
|
||||||
services.inventree.config = {
|
|
||||||
plugins_enabled = false;
|
|
||||||
plugin_file = "${cfg.dataDir}/plugins.txt";
|
|
||||||
plugin_dir = "${cfg.dataDir}/plugins";
|
|
||||||
database = {
|
|
||||||
ENGINE = "postgresql";
|
|
||||||
NAME = "inventree";
|
|
||||||
HOST = "/run/postgresql";
|
|
||||||
};
|
|
||||||
};
|
|
||||||
|
|
||||||
services.postgresql = {
|
|
||||||
enable = true;
|
|
||||||
ensureDatabases = [ "inventree" ];
|
|
||||||
ensureUsers = [
|
|
||||||
{
|
|
||||||
name = "inventree";
|
|
||||||
ensureDBOwnership = true;
|
|
||||||
}
|
|
||||||
];
|
|
||||||
};
|
|
||||||
|
|
||||||
users.users.inventree = {
|
|
||||||
group = "inventree";
|
|
||||||
isSystemUser = true;
|
|
||||||
description = "InvenTree daemon user";
|
|
||||||
};
|
|
||||||
|
|
||||||
users.groups.inventree = { };
|
|
||||||
|
|
||||||
services.nginx.enable = true;
|
|
||||||
|
|
||||||
services.nginx.virtualHosts.${cfg.hostName} = {
|
|
||||||
locations =
|
|
||||||
let
|
|
||||||
unixPath = config.systemd.sockets.inventree-gunicorn.socketConfig.ListenStream;
|
|
||||||
in
|
|
||||||
{
|
|
||||||
"/" = {
|
|
||||||
extraConfig = ''
|
|
||||||
client_max_body_size 100M;
|
|
||||||
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
|
|
||||||
'';
|
|
||||||
proxyPass = "http://unix:${unixPath}";
|
|
||||||
};
|
|
||||||
"/static/" = {
|
|
||||||
alias = "${cfg.config.static_root}/";
|
|
||||||
extraConfig = ''
|
|
||||||
expires 30d;
|
|
||||||
'';
|
|
||||||
};
|
|
||||||
"/media/" = {
|
|
||||||
alias = "${cfg.config.media_root}/";
|
|
||||||
extraConfig = ''
|
|
||||||
auth_request /auth;
|
|
||||||
'';
|
|
||||||
};
|
|
||||||
"/auth" = {
|
|
||||||
extraConfig = ''
|
|
||||||
internal;
|
|
||||||
'';
|
|
||||||
proxyPass = "http://unix:${unixPath}:/auth/";
|
|
||||||
};
|
|
||||||
};
|
|
||||||
};
|
|
||||||
|
|
||||||
systemd.targets.inventree = {
|
|
||||||
description = "Target for all InvenTree services";
|
|
||||||
wantedBy = [ "multi-user.target" ];
|
|
||||||
wants = [ "network-online.target" ];
|
|
||||||
after = [ "network-online.target" ];
|
|
||||||
};
|
|
||||||
|
|
||||||
systemd.services.inventree-config = {
|
|
||||||
description = "Inventree config generation";
|
|
||||||
wantedBy = [ "inventree.target" ];
|
|
||||||
partOf = [ "inventree.target" ];
|
|
||||||
before = [
|
|
||||||
"inventree-static.service"
|
|
||||||
"inventree-gunicorn.service"
|
|
||||||
"inventree-qcluster.service"
|
|
||||||
];
|
|
||||||
serviceConfig = {
|
|
||||||
# User = "root";
|
|
||||||
# Group = "root";
|
|
||||||
User = "inventree";
|
|
||||||
Group = "inventree";
|
|
||||||
Type = "oneshot";
|
|
||||||
RemainAfterExit = true;
|
|
||||||
PrivateTmp = true;
|
|
||||||
};
|
|
||||||
environment = env;
|
|
||||||
script = ''
|
|
||||||
set -euo pipefail
|
|
||||||
|
|
||||||
umask u=rwx,g=,o=
|
|
||||||
|
|
||||||
# chown inventree:inventree ${configFile}
|
|
||||||
|
|
||||||
${pkg}/opt/inventree/src/backend/InvenTree/manage.py migrate
|
|
||||||
'';
|
|
||||||
};
|
|
||||||
|
|
||||||
systemd.services.inventree-static = {
|
|
||||||
description = "InvenTree static migration";
|
|
||||||
wantedBy = [ "inventree.target" ];
|
|
||||||
partOf = [ "inventree.target" ];
|
|
||||||
before = [ "inventree-gunicorn.service" ];
|
|
||||||
environment = env;
|
|
||||||
serviceConfig = {
|
|
||||||
User = "inventree";
|
|
||||||
Group = "inventree";
|
|
||||||
StateDirectory = "inventree";
|
|
||||||
#RuntimeDirectory = "inventree";
|
|
||||||
PrivateTmp = true;
|
|
||||||
ExecStart = ''
|
|
||||||
${pkg}/opt/inventree/src/backend/InvenTree/manage.py collectstatic --no-input
|
|
||||||
'';
|
|
||||||
};
|
|
||||||
};
|
|
||||||
|
|
||||||
systemd.services.inventree-gunicorn = {
|
|
||||||
description = "InvenTree Gunicorn server";
|
|
||||||
requiredBy = [ "inventree.target" ];
|
|
||||||
partOf = [ "inventree.target" ];
|
|
||||||
#wantedBy = [ "inventree.target" ];
|
|
||||||
environment = env;
|
|
||||||
serviceConfig = {
|
|
||||||
User = "inventree";
|
|
||||||
Group = "inventree";
|
|
||||||
StateDirectory = "inventree";
|
|
||||||
#RuntimeDirectory = "inventree";
|
|
||||||
PrivateTmp = true;
|
|
||||||
ExecStart = ''
|
|
||||||
${pkg.gunicorn}/bin/gunicorn InvenTree.wsgi \
|
|
||||||
--pythonpath ${pkg}/opt/inventree/src/backend/InvenTree
|
|
||||||
'';
|
|
||||||
};
|
|
||||||
};
|
|
||||||
|
|
||||||
systemd.sockets.inventree-gunicorn = {
|
|
||||||
wantedBy = [ "sockets.target" ];
|
|
||||||
partOf = [ "inventree.target" ];
|
|
||||||
socketConfig.ListenStream = "/run/inventree/gunicorn.socket";
|
|
||||||
};
|
|
||||||
|
|
||||||
systemd.services.inventree-qcluster = {
|
|
||||||
description = "InvenTree qcluster server";
|
|
||||||
requiredBy = [ "inventree.target" ];
|
|
||||||
wantedBy = [ "inventree.target" ];
|
|
||||||
partOf = [ "inventree.target" ];
|
|
||||||
environment = env;
|
|
||||||
serviceConfig = {
|
|
||||||
User = "inventree";
|
|
||||||
Group = "inventree";
|
|
||||||
StateDirectory = "inventree";
|
|
||||||
#RuntimeDirectory = "inventree";
|
|
||||||
PrivateTmp = true;
|
|
||||||
ExecStart = ''
|
|
||||||
${pkg}/opt/inventree/src/backend/InvenTree/manage.py qcluster
|
|
||||||
'';
|
|
||||||
};
|
|
||||||
};
|
|
||||||
};
|
|
||||||
}
|
|
||||||
@@ -1,161 +0,0 @@
|
|||||||
{
|
|
||||||
stdenvNoCC,
|
|
||||||
python3,
|
|
||||||
fetchFromGitHub,
|
|
||||||
fetchYarnDeps,
|
|
||||||
yarnConfigHook,
|
|
||||||
nodejs,
|
|
||||||
}:
|
|
||||||
let
|
|
||||||
version = "1.1.0";
|
|
||||||
|
|
||||||
src = fetchFromGitHub {
|
|
||||||
owner = "inventree";
|
|
||||||
repo = "InvenTree";
|
|
||||||
tag = "${version}";
|
|
||||||
hash = "sha256-GAATo5zkkNCes9fCQsYUsZ9auhgYEUnevN4obWj3ZRA=";
|
|
||||||
};
|
|
||||||
|
|
||||||
frontend = stdenvNoCC.mkDerivation {
|
|
||||||
name = "inventree-frontend";
|
|
||||||
inherit version src;
|
|
||||||
|
|
||||||
yarnOfflineCache = fetchYarnDeps {
|
|
||||||
yarnLock = "${src}/src/frontend/yarn.lock";
|
|
||||||
hash = "sha256-Ijbkx+INZgsvMhkzo8h/FUY75W3UHnKAdUjQRD8kJZw=";
|
|
||||||
};
|
|
||||||
|
|
||||||
nativeBuildInputs = [
|
|
||||||
yarnConfigHook
|
|
||||||
nodejs
|
|
||||||
];
|
|
||||||
|
|
||||||
patchPhase = ''
|
|
||||||
runHook prePatch
|
|
||||||
cd src/frontend
|
|
||||||
runHook postPatch
|
|
||||||
'';
|
|
||||||
|
|
||||||
buildPhase = ''
|
|
||||||
echo "Running lingui"
|
|
||||||
./node_modules/.bin/lingui compile --typescript
|
|
||||||
echo building lib
|
|
||||||
./node_modules/.bin/tsc --p ./tsconfig.lib.json
|
|
||||||
./node_modules/.bin/vite --config vite.lib.config.ts build
|
|
||||||
echo "Running tsc"
|
|
||||||
./node_modules/.bin/tsc
|
|
||||||
echo "Running vite"
|
|
||||||
./node_modules/.bin/vite build --emptyOutDir --outDir $out
|
|
||||||
'';
|
|
||||||
};
|
|
||||||
|
|
||||||
in
|
|
||||||
python3.pkgs.buildPythonApplication rec {
|
|
||||||
pname = "InvenTree";
|
|
||||||
inherit version src;
|
|
||||||
|
|
||||||
format = "other";
|
|
||||||
|
|
||||||
dependencies =
|
|
||||||
with python3.pkgs;
|
|
||||||
[
|
|
||||||
coreapi
|
|
||||||
cryptography
|
|
||||||
distutils
|
|
||||||
dj-rest-auth
|
|
||||||
django
|
|
||||||
django-allauth
|
|
||||||
django-allauth.optional-dependencies.openid
|
|
||||||
django-allauth.optional-dependencies.mfa
|
|
||||||
django-allauth.optional-dependencies.socialaccount
|
|
||||||
django-cleanup
|
|
||||||
django-cors-headers
|
|
||||||
django-dbbackup
|
|
||||||
django-error-report-2
|
|
||||||
django-filter
|
|
||||||
django-flags
|
|
||||||
django-formtools
|
|
||||||
django-ical
|
|
||||||
django-js-asset
|
|
||||||
django-maintenance-mode
|
|
||||||
django-markdownify
|
|
||||||
django-money
|
|
||||||
django-mptt
|
|
||||||
django-mailbox
|
|
||||||
django-anymail
|
|
||||||
django-redis
|
|
||||||
django-oauth-toolkit
|
|
||||||
django-otp
|
|
||||||
django-q-sentry
|
|
||||||
django-q2
|
|
||||||
django-redis
|
|
||||||
django-sesame
|
|
||||||
django-sql-utils
|
|
||||||
django-structlog
|
|
||||||
django-stdimage
|
|
||||||
django-taggit
|
|
||||||
django-user-sessions
|
|
||||||
django-weasyprint
|
|
||||||
djangorestframework
|
|
||||||
djangorestframework-simplejwt
|
|
||||||
djangorestframework-simplejwt.optional-dependencies.crypto
|
|
||||||
django-xforwardedfor-middleware
|
|
||||||
django-storages
|
|
||||||
drf-spectacular
|
|
||||||
dulwich
|
|
||||||
feedparser
|
|
||||||
gunicorn
|
|
||||||
pdf2image
|
|
||||||
pillow
|
|
||||||
pint
|
|
||||||
pip-licenses
|
|
||||||
pypdf
|
|
||||||
python-barcode
|
|
||||||
python-barcode.optional-dependencies.images
|
|
||||||
python-dotenv
|
|
||||||
pyyaml
|
|
||||||
qrcode
|
|
||||||
qrcode.optional-dependencies.pil
|
|
||||||
rapidfuzz
|
|
||||||
sentry-sdk
|
|
||||||
tablib
|
|
||||||
tablib.optional-dependencies.xls
|
|
||||||
tablib.optional-dependencies.xlsx
|
|
||||||
tablib.optional-dependencies.yaml
|
|
||||||
weasyprint
|
|
||||||
whitenoise
|
|
||||||
|
|
||||||
psycopg2
|
|
||||||
fido2
|
|
||||||
|
|
||||||
opentelemetry-api
|
|
||||||
opentelemetry-sdk
|
|
||||||
opentelemetry-exporter-otlp
|
|
||||||
opentelemetry-instrumentation-django
|
|
||||||
opentelemetry-instrumentation-requests
|
|
||||||
opentelemetry-instrumentation-redis
|
|
||||||
opentelemetry-instrumentation-sqlite3
|
|
||||||
opentelemetry-instrumentation-system-metrics
|
|
||||||
opentelemetry-instrumentation-wsgi
|
|
||||||
]
|
|
||||||
++ django-anymail.optional-dependencies.amazon-ses;
|
|
||||||
|
|
||||||
installPhase = ''
|
|
||||||
substituteInPlace src/backend/InvenTree/InvenTree/settings.py --replace-fail "django_slowtests.testrunner.DiscoverSlowestTestsRunner" "django.test.runner.DiscoverRunner"
|
|
||||||
|
|
||||||
mkdir -p $out/opt/inventree
|
|
||||||
cp -r . $out/opt/inventree
|
|
||||||
|
|
||||||
echo "Installing frontend"
|
|
||||||
|
|
||||||
mkdir -p $out/opt/inventree/src/backend/InvenTree/web/static/web
|
|
||||||
cp -r ${frontend}/* $out/opt/inventree/src/backend/InvenTree/web/static/web/
|
|
||||||
cp -r ${frontend}/.* $out/opt/inventree/src/backend/InvenTree/web/static/web/
|
|
||||||
'';
|
|
||||||
|
|
||||||
passthru = {
|
|
||||||
pythonPath = python3.pkgs.makePythonPath dependencies;
|
|
||||||
gunicorn = python3.pkgs.gunicorn;
|
|
||||||
inherit frontend;
|
|
||||||
};
|
|
||||||
}
|
|
||||||
@@ -2,28 +2,4 @@ final: prev: {
|
|||||||
think-gtcm = final.callPackage ./think-gtcm.nix { };
|
think-gtcm = final.callPackage ./think-gtcm.nix { };
|
||||||
think-backend-gtcm = final.callPackage ./think-backend-gtcm.nix { php = final.php83; };
|
think-backend-gtcm = final.callPackage ./think-backend-gtcm.nix { php = final.php83; };
|
||||||
gtcm-file-uploader = final.callPackage ./gtcm-file-uploader.nix { };
|
gtcm-file-uploader = final.callPackage ./gtcm-file-uploader.nix { };
|
||||||
|
|
||||||
pythonPackagesExtensions = prev.pythonPackagesExtensions ++ [
|
|
||||||
(py-final: py-prev: {
|
|
||||||
django-dbbackup = py-final.callPackage ./python/django-dbbackup { };
|
|
||||||
django-error-report-2 = py-final.callPackage ./python/django-error-report-2 { };
|
|
||||||
django-flags = py-final.callPackage ./python/django-flags { };
|
|
||||||
django-ical = py-final.callPackage ./python/django-ical { };
|
|
||||||
django-markdownify = py-final.callPackage ./python/django-markdownify { };
|
|
||||||
django-money = py-final.callPackage ./python/django-money { };
|
|
||||||
django-q-sentry = py-final.callPackage ./python/django-q-sentry { };
|
|
||||||
django-recurrence = py-final.callPackage ./python/django-recurrence { };
|
|
||||||
django-slowtests = py-final.callPackage ./python/django-slowtests { };
|
|
||||||
django-structlog = py-final.callPackage ./python/django-structlog { };
|
|
||||||
django-stdimage = py-final.callPackage ./python/django-stdimage { };
|
|
||||||
django-user-sessions = py-final.callPackage ./python/django-user-sessions { };
|
|
||||||
django-weasyprint = py-final.callPackage ./python/django-weasyprint { };
|
|
||||||
django-xforwardedfor-middleware = py-final.callPackage ./python/django-xforwardedfor-middleware { };
|
|
||||||
pip-licenses = py-final.callPackage ./python/pip-licenses { };
|
|
||||||
py-moneyed = py-final.callPackage ./python/py-moneyed { };
|
|
||||||
pytest-pycodestyle = py-final.callPackage ./python/pytest-codestyle { };
|
|
||||||
sentry-sdk = py-final.callPackage ./python/sentry-sdk { };
|
|
||||||
})
|
|
||||||
];
|
|
||||||
inventree = final.callPackage ./inventree { python3 = final.python312; };
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,42 +0,0 @@
|
|||||||
{
|
|
||||||
lib,
|
|
||||||
buildPythonPackage,
|
|
||||||
fetchFromGitHub,
|
|
||||||
setuptools,
|
|
||||||
wheel,
|
|
||||||
django,
|
|
||||||
pytz,
|
|
||||||
}:
|
|
||||||
|
|
||||||
buildPythonPackage rec {
|
|
||||||
pname = "django-dbbackup";
|
|
||||||
version = "4.2.1";
|
|
||||||
pyproject = true;
|
|
||||||
|
|
||||||
src = fetchFromGitHub {
|
|
||||||
owner = "jazzband";
|
|
||||||
repo = "django-dbbackup";
|
|
||||||
rev = version;
|
|
||||||
hash = "sha256-GD+f9mbImGPQ6MOUK3ftHqiGv7TT39jNQsFvd0dnnWU=";
|
|
||||||
};
|
|
||||||
|
|
||||||
build-system = [
|
|
||||||
setuptools
|
|
||||||
wheel
|
|
||||||
];
|
|
||||||
|
|
||||||
dependencies = [
|
|
||||||
django
|
|
||||||
pytz
|
|
||||||
];
|
|
||||||
|
|
||||||
pythonImportsCheck = [ "dbbackup" ];
|
|
||||||
|
|
||||||
meta = {
|
|
||||||
description = "Management commands to help backup and restore your project database and media files";
|
|
||||||
homepage = "https://github.com/jazzband/django-dbbackup";
|
|
||||||
license = lib.licenses.bsd3;
|
|
||||||
maintainers = with lib.maintainers; [ ];
|
|
||||||
mainProgram = "django-dbbackup";
|
|
||||||
};
|
|
||||||
}
|
|
||||||
@@ -1,37 +0,0 @@
|
|||||||
{
|
|
||||||
lib,
|
|
||||||
buildPythonPackage,
|
|
||||||
fetchFromGitHub,
|
|
||||||
setuptools,
|
|
||||||
wheel,
|
|
||||||
django,
|
|
||||||
}:
|
|
||||||
|
|
||||||
buildPythonPackage rec {
|
|
||||||
pname = "django-error-report-2";
|
|
||||||
version = "0.4.2";
|
|
||||||
pyproject = true;
|
|
||||||
|
|
||||||
src = fetchFromGitHub {
|
|
||||||
owner = "matmair";
|
|
||||||
repo = "django-error-report-2";
|
|
||||||
rev = version;
|
|
||||||
hash = "sha256-ZCaslqgruJxM8345/jSlZGruM+27H9hvwL0wtPkUzc0=";
|
|
||||||
};
|
|
||||||
|
|
||||||
build-system = [
|
|
||||||
setuptools
|
|
||||||
wheel
|
|
||||||
];
|
|
||||||
|
|
||||||
dependencies = [ django ];
|
|
||||||
|
|
||||||
pythonImportsCheck = [ "error_report" ];
|
|
||||||
|
|
||||||
meta = {
|
|
||||||
description = "Log/View Django server errors";
|
|
||||||
homepage = "https://github.com/matmair/django-error-report-2";
|
|
||||||
license = lib.licenses.mit;
|
|
||||||
maintainers = with lib.maintainers; [ ];
|
|
||||||
};
|
|
||||||
}
|
|
||||||
@@ -1,37 +0,0 @@
|
|||||||
{
|
|
||||||
lib,
|
|
||||||
buildPythonPackage,
|
|
||||||
fetchFromGitHub,
|
|
||||||
setuptools,
|
|
||||||
wheel,
|
|
||||||
django,
|
|
||||||
}:
|
|
||||||
|
|
||||||
buildPythonPackage rec {
|
|
||||||
pname = "django-flags";
|
|
||||||
version = "5.0.13";
|
|
||||||
pyproject = true;
|
|
||||||
|
|
||||||
src = fetchFromGitHub {
|
|
||||||
owner = "cfpb";
|
|
||||||
repo = "django-flags";
|
|
||||||
rev = version;
|
|
||||||
hash = "sha256-WPMfFYoP6WaVzZmVtqAz4LlY761aCRyPhd5npc8bOOI=";
|
|
||||||
};
|
|
||||||
|
|
||||||
build-system = [
|
|
||||||
setuptools
|
|
||||||
wheel
|
|
||||||
];
|
|
||||||
|
|
||||||
dependencies = [ django ];
|
|
||||||
|
|
||||||
pythonImportsCheck = [ "flags" ];
|
|
||||||
|
|
||||||
meta = {
|
|
||||||
description = "Feature flags for Django projects";
|
|
||||||
homepage = "https://github.com/cfpb/django-flags";
|
|
||||||
license = lib.licenses.cc0;
|
|
||||||
maintainers = with lib.maintainers; [ ];
|
|
||||||
};
|
|
||||||
}
|
|
||||||
@@ -1,46 +0,0 @@
|
|||||||
{
|
|
||||||
lib,
|
|
||||||
buildPythonPackage,
|
|
||||||
fetchFromGitHub,
|
|
||||||
setuptools,
|
|
||||||
setuptools-scm,
|
|
||||||
wheel,
|
|
||||||
django,
|
|
||||||
django-recurrence,
|
|
||||||
icalendar,
|
|
||||||
}:
|
|
||||||
|
|
||||||
buildPythonPackage rec {
|
|
||||||
pname = "django-ical";
|
|
||||||
version = "1.9.2";
|
|
||||||
pyproject = true;
|
|
||||||
|
|
||||||
src = fetchFromGitHub {
|
|
||||||
owner = "jazzband";
|
|
||||||
repo = "django-ical";
|
|
||||||
rev = version;
|
|
||||||
hash = "sha256-DUe0loayGcUS7MTyLn+g0KBxbIY7VsaoQNHGSMbMI3U=";
|
|
||||||
};
|
|
||||||
|
|
||||||
build-system = [
|
|
||||||
setuptools
|
|
||||||
setuptools-scm
|
|
||||||
wheel
|
|
||||||
];
|
|
||||||
|
|
||||||
dependencies = [
|
|
||||||
django
|
|
||||||
django-recurrence
|
|
||||||
icalendar
|
|
||||||
];
|
|
||||||
|
|
||||||
pythonImportsCheck = [ "django_ical" ];
|
|
||||||
|
|
||||||
meta = {
|
|
||||||
description = "ICal feeds for Django based on Django's syndication feed framework";
|
|
||||||
homepage = "https://github.com/jazzband/django-ical";
|
|
||||||
changelog = "https://github.com/jazzband/django-ical/blob/${src.rev}/CHANGES.rst";
|
|
||||||
license = lib.licenses.mit;
|
|
||||||
maintainers = with lib.maintainers; [ ];
|
|
||||||
};
|
|
||||||
}
|
|
||||||
@@ -1,39 +0,0 @@
|
|||||||
{
|
|
||||||
lib,
|
|
||||||
buildPythonPackage,
|
|
||||||
fetchFromGitHub,
|
|
||||||
setuptools,
|
|
||||||
bleach,
|
|
||||||
django,
|
|
||||||
markdown,
|
|
||||||
}:
|
|
||||||
|
|
||||||
buildPythonPackage rec {
|
|
||||||
pname = "django-markdownify";
|
|
||||||
version = "0.9.5";
|
|
||||||
pyproject = true;
|
|
||||||
|
|
||||||
src = fetchFromGitHub {
|
|
||||||
owner = "erwinmatijsen";
|
|
||||||
repo = "django-markdownify";
|
|
||||||
rev = version;
|
|
||||||
hash = "sha256-KYU8p8NRD4EIS/KhOk9nvmXCf0RWEc+IFZ57YtsDSWE=";
|
|
||||||
};
|
|
||||||
|
|
||||||
build-system = [ setuptools ];
|
|
||||||
|
|
||||||
dependencies = [
|
|
||||||
bleach
|
|
||||||
django
|
|
||||||
markdown
|
|
||||||
];
|
|
||||||
|
|
||||||
pythonImportsCheck = [ "markdownify" ];
|
|
||||||
|
|
||||||
meta = {
|
|
||||||
description = "Markdown template filter for Django";
|
|
||||||
homepage = "https://github.com/erwinmatijsen/django-markdownify";
|
|
||||||
license = lib.licenses.mit;
|
|
||||||
maintainers = with lib.maintainers; [ ];
|
|
||||||
};
|
|
||||||
}
|
|
||||||
@@ -1,41 +0,0 @@
|
|||||||
{
|
|
||||||
lib,
|
|
||||||
buildPythonPackage,
|
|
||||||
fetchFromGitHub,
|
|
||||||
setuptools,
|
|
||||||
wheel,
|
|
||||||
django,
|
|
||||||
py-moneyed,
|
|
||||||
}:
|
|
||||||
|
|
||||||
buildPythonPackage rec {
|
|
||||||
pname = "django-money";
|
|
||||||
version = "3.2";
|
|
||||||
pyproject = true;
|
|
||||||
|
|
||||||
src = fetchFromGitHub {
|
|
||||||
owner = "django-money";
|
|
||||||
repo = "django-money";
|
|
||||||
rev = version;
|
|
||||||
hash = "sha256-eL26NsreUqtMJ26TmvmB53EJI4Sjs7qjFDnnt4N0vdI=";
|
|
||||||
};
|
|
||||||
|
|
||||||
build-system = [
|
|
||||||
setuptools
|
|
||||||
wheel
|
|
||||||
];
|
|
||||||
|
|
||||||
dependencies = [
|
|
||||||
django
|
|
||||||
py-moneyed
|
|
||||||
];
|
|
||||||
|
|
||||||
pythonImportsCheck = [ "djmoney" ];
|
|
||||||
|
|
||||||
meta = {
|
|
||||||
description = "Money fields for Django forms and models";
|
|
||||||
homepage = "https://github.com/django-money/django-money";
|
|
||||||
license = lib.licenses.bsd3;
|
|
||||||
maintainers = with lib.maintainers; [ ];
|
|
||||||
};
|
|
||||||
}
|
|
||||||
@@ -1,37 +0,0 @@
|
|||||||
{
|
|
||||||
lib,
|
|
||||||
buildPythonPackage,
|
|
||||||
fetchFromGitHub,
|
|
||||||
poetry-core,
|
|
||||||
setuptools,
|
|
||||||
sentry-sdk,
|
|
||||||
}:
|
|
||||||
|
|
||||||
buildPythonPackage rec {
|
|
||||||
pname = "django-q-sentry";
|
|
||||||
version = "0.1.6";
|
|
||||||
pyproject = true;
|
|
||||||
|
|
||||||
src = fetchFromGitHub {
|
|
||||||
owner = "danielwelch";
|
|
||||||
repo = "django-q-sentry";
|
|
||||||
rev = "d3a43a90c82734244d5ebf3295652223053f1354";
|
|
||||||
hash = "sha256-3C7A+X18c7p19HWD/uPRtAMf29VjmrfXXh2z5PPOREY=";
|
|
||||||
};
|
|
||||||
|
|
||||||
build-system = [
|
|
||||||
poetry-core
|
|
||||||
setuptools
|
|
||||||
];
|
|
||||||
|
|
||||||
dependencies = [ sentry-sdk ];
|
|
||||||
|
|
||||||
pythonImportsCheck = [ "django_q_sentry" ];
|
|
||||||
|
|
||||||
meta = {
|
|
||||||
description = "Bringing Sentry error tracking to Django Q";
|
|
||||||
homepage = "https://github.com/danielwelch/django-q-sentry";
|
|
||||||
license = lib.licenses.mit;
|
|
||||||
maintainers = with lib.maintainers; [ ];
|
|
||||||
};
|
|
||||||
}
|
|
||||||
@@ -1,56 +0,0 @@
|
|||||||
{
|
|
||||||
lib,
|
|
||||||
buildPythonPackage,
|
|
||||||
fetchFromGitHub,
|
|
||||||
pdm-backend,
|
|
||||||
django,
|
|
||||||
flake8,
|
|
||||||
pytest,
|
|
||||||
pytest-cov,
|
|
||||||
pytest-django,
|
|
||||||
pytest-sugar,
|
|
||||||
python-dateutil,
|
|
||||||
sphinx,
|
|
||||||
sphinx-rtd-theme,
|
|
||||||
tox,
|
|
||||||
}:
|
|
||||||
|
|
||||||
buildPythonPackage rec {
|
|
||||||
pname = "django-recurrence";
|
|
||||||
version = "1.12.1";
|
|
||||||
pyproject = true;
|
|
||||||
|
|
||||||
src = fetchFromGitHub {
|
|
||||||
owner = "jazzband";
|
|
||||||
repo = "django-recurrence";
|
|
||||||
rev = version;
|
|
||||||
hash = "sha256-Q33zyMa1wI13RNLxynGAJHlagahpnFHCmZbHp0aPC/w=";
|
|
||||||
};
|
|
||||||
|
|
||||||
build-system = [ pdm-backend ];
|
|
||||||
|
|
||||||
dependencies = [
|
|
||||||
django
|
|
||||||
flake8
|
|
||||||
pytest
|
|
||||||
pytest-cov
|
|
||||||
pytest-django
|
|
||||||
pytest-sugar
|
|
||||||
python-dateutil
|
|
||||||
sphinx
|
|
||||||
sphinx-rtd-theme
|
|
||||||
tox
|
|
||||||
];
|
|
||||||
|
|
||||||
pythonRelaxDeps = true;
|
|
||||||
|
|
||||||
pythonImportsCheck = [ "recurrence" ];
|
|
||||||
|
|
||||||
meta = {
|
|
||||||
description = "Utility for working with recurring dates in Django";
|
|
||||||
homepage = "https://github.com/django-recurrence/django-recurrence";
|
|
||||||
changelog = "https://github.com/django-recurrence/django-recurrence/blob/${src.rev}/CHANGES.rst";
|
|
||||||
license = lib.licenses.bsd3;
|
|
||||||
maintainers = with lib.maintainers; [ ];
|
|
||||||
};
|
|
||||||
}
|
|
||||||
@@ -1,38 +0,0 @@
|
|||||||
{
|
|
||||||
lib,
|
|
||||||
buildPythonPackage,
|
|
||||||
fetchFromGitHub,
|
|
||||||
setuptools,
|
|
||||||
wheel,
|
|
||||||
django,
|
|
||||||
}:
|
|
||||||
|
|
||||||
buildPythonPackage rec {
|
|
||||||
pname = "django-slowtests";
|
|
||||||
version = "1.1.1";
|
|
||||||
pyproject = true;
|
|
||||||
|
|
||||||
src = fetchFromGitHub {
|
|
||||||
owner = "realpython";
|
|
||||||
repo = "django-slow-tests";
|
|
||||||
rev = version;
|
|
||||||
hash = "sha256-gW9AZiMpXJp1m2X1cbm6GdZ9cH+TFqjNLQJFmsvGjB0=";
|
|
||||||
};
|
|
||||||
|
|
||||||
build-system = [
|
|
||||||
setuptools
|
|
||||||
wheel
|
|
||||||
];
|
|
||||||
|
|
||||||
dependencies = [ django ];
|
|
||||||
|
|
||||||
pythonImportsCheck = [ "django_slowtests" ];
|
|
||||||
|
|
||||||
meta = {
|
|
||||||
description = "Locate your slowest tests";
|
|
||||||
homepage = "https://github.com/realpython/django-slow-tests";
|
|
||||||
changelog = "https://github.com/realpython/django-slow-tests/blob/${src.rev}/CHANGELOG.rst";
|
|
||||||
license = lib.licenses.mit;
|
|
||||||
maintainers = with lib.maintainers; [ ];
|
|
||||||
};
|
|
||||||
}
|
|
||||||
@@ -1,51 +0,0 @@
|
|||||||
{
|
|
||||||
lib,
|
|
||||||
buildPythonPackage,
|
|
||||||
fetchFromGitHub,
|
|
||||||
setuptools,
|
|
||||||
setuptools-scm,
|
|
||||||
wheel,
|
|
||||||
django,
|
|
||||||
pillow,
|
|
||||||
gettext,
|
|
||||||
}:
|
|
||||||
|
|
||||||
buildPythonPackage rec {
|
|
||||||
pname = "django-stdimage";
|
|
||||||
version = "6.0.2";
|
|
||||||
pyproject = true;
|
|
||||||
|
|
||||||
src = fetchFromGitHub {
|
|
||||||
owner = "codingjoe";
|
|
||||||
repo = "django-stdimage";
|
|
||||||
rev = version;
|
|
||||||
hash = "sha256-uwVU3Huc5fitAweShJjcMW//GBeIpJcxqKKLGo/EdIs=";
|
|
||||||
};
|
|
||||||
|
|
||||||
build-system = [
|
|
||||||
setuptools
|
|
||||||
setuptools-scm
|
|
||||||
wheel
|
|
||||||
];
|
|
||||||
|
|
||||||
dependencies = [
|
|
||||||
django
|
|
||||||
pillow
|
|
||||||
];
|
|
||||||
|
|
||||||
nativeBuildInputs = [ gettext ];
|
|
||||||
|
|
||||||
preBuild = ''
|
|
||||||
echo "bla bla"
|
|
||||||
echo $PATH
|
|
||||||
'';
|
|
||||||
|
|
||||||
pythonImportsCheck = [ "stdimage" ];
|
|
||||||
|
|
||||||
meta = {
|
|
||||||
description = "";
|
|
||||||
homepage = "https://github.com/codingjoe/django-stdimage";
|
|
||||||
license = lib.licenses.mit;
|
|
||||||
maintainers = with lib.maintainers; [ ];
|
|
||||||
};
|
|
||||||
}
|
|
||||||
@@ -1,48 +0,0 @@
|
|||||||
{
|
|
||||||
lib,
|
|
||||||
buildPythonPackage,
|
|
||||||
fetchFromGitHub,
|
|
||||||
setuptools,
|
|
||||||
asgiref,
|
|
||||||
django,
|
|
||||||
django-ipware,
|
|
||||||
structlog,
|
|
||||||
celery,
|
|
||||||
django-extensions,
|
|
||||||
}:
|
|
||||||
|
|
||||||
buildPythonPackage rec {
|
|
||||||
pname = "django-structlog";
|
|
||||||
version = "9.1.1";
|
|
||||||
pyproject = true;
|
|
||||||
|
|
||||||
src = fetchFromGitHub {
|
|
||||||
owner = "jrobichaud";
|
|
||||||
repo = "django-structlog";
|
|
||||||
rev = version;
|
|
||||||
hash = "sha256-SEigOdlXZtfLAgRgGkv/eDNDAiiHd7YthRJ/H6e1v5U=";
|
|
||||||
};
|
|
||||||
|
|
||||||
build-system = [ setuptools ];
|
|
||||||
|
|
||||||
dependencies = [
|
|
||||||
asgiref
|
|
||||||
django
|
|
||||||
django-ipware
|
|
||||||
structlog
|
|
||||||
];
|
|
||||||
|
|
||||||
optional-dependencies = {
|
|
||||||
celery = [ celery ];
|
|
||||||
commands = [ django-extensions ];
|
|
||||||
};
|
|
||||||
|
|
||||||
pythonImportsCheck = [ "django_structlog" ];
|
|
||||||
|
|
||||||
meta = {
|
|
||||||
description = "";
|
|
||||||
homepage = "https://github.com/jrobichaud/django-structlog";
|
|
||||||
license = lib.licenses.mit;
|
|
||||||
maintainers = with lib.maintainers; [ ];
|
|
||||||
};
|
|
||||||
}
|
|
||||||
@@ -1,39 +0,0 @@
|
|||||||
{
|
|
||||||
lib,
|
|
||||||
buildPythonPackage,
|
|
||||||
fetchFromGitHub,
|
|
||||||
setuptools,
|
|
||||||
setuptools-scm,
|
|
||||||
wheel,
|
|
||||||
django,
|
|
||||||
}:
|
|
||||||
|
|
||||||
buildPythonPackage rec {
|
|
||||||
pname = "django-user-sessions";
|
|
||||||
version = "2.0.0";
|
|
||||||
pyproject = true;
|
|
||||||
|
|
||||||
src = fetchFromGitHub {
|
|
||||||
owner = "jazzband";
|
|
||||||
repo = "django-user-sessions";
|
|
||||||
rev = version;
|
|
||||||
hash = "sha256-Wexy6G2pZ8LTnqtJkBZIePV7qhQW8gu/mKiQfZtgf/o=";
|
|
||||||
};
|
|
||||||
|
|
||||||
build-system = [
|
|
||||||
setuptools
|
|
||||||
setuptools-scm
|
|
||||||
wheel
|
|
||||||
];
|
|
||||||
|
|
||||||
dependencies = [ django ];
|
|
||||||
|
|
||||||
pythonImportsCheck = [ "user_sessions" ];
|
|
||||||
|
|
||||||
meta = {
|
|
||||||
description = "Extend Django sessions with a foreign key back to the user, allowing enumerating all user's sessions";
|
|
||||||
homepage = "http://github.com/jazzband/django-user-sessions";
|
|
||||||
license = lib.licenses.mit;
|
|
||||||
maintainers = with lib.maintainers; [ ];
|
|
||||||
};
|
|
||||||
}
|
|
||||||
@@ -1,38 +0,0 @@
|
|||||||
{
|
|
||||||
lib,
|
|
||||||
buildPythonPackage,
|
|
||||||
fetchFromGitHub,
|
|
||||||
setuptools,
|
|
||||||
django,
|
|
||||||
weasyprint,
|
|
||||||
}:
|
|
||||||
|
|
||||||
buildPythonPackage rec {
|
|
||||||
pname = "django-weasyprint";
|
|
||||||
version = "2.4.0";
|
|
||||||
pyproject = true;
|
|
||||||
|
|
||||||
src = fetchFromGitHub {
|
|
||||||
owner = "fdemmer";
|
|
||||||
repo = "django-weasyprint";
|
|
||||||
rev = "v${version}";
|
|
||||||
hash = "sha256-eSh1p+5MyYb6GIEgSdlFxPzVCenlkwSCTkTzgKjezIg=";
|
|
||||||
};
|
|
||||||
|
|
||||||
build-system = [ setuptools ];
|
|
||||||
|
|
||||||
dependencies = [
|
|
||||||
django
|
|
||||||
weasyprint
|
|
||||||
];
|
|
||||||
|
|
||||||
pythonImportsCheck = [ "django_weasyprint" ];
|
|
||||||
|
|
||||||
meta = {
|
|
||||||
description = "A Django class-based view generating PDF resposes using WeasyPrint";
|
|
||||||
homepage = "https://github.com/fdemmer/django-weasyprint";
|
|
||||||
changelog = "https://github.com/fdemmer/django-weasyprint/blob/${src.rev}/CHANGELOG.md";
|
|
||||||
license = lib.licenses.asl20;
|
|
||||||
maintainers = with lib.maintainers; [ ];
|
|
||||||
};
|
|
||||||
}
|
|
||||||
@@ -1,37 +0,0 @@
|
|||||||
{
|
|
||||||
lib,
|
|
||||||
buildPythonPackage,
|
|
||||||
fetchFromGitHub,
|
|
||||||
setuptools,
|
|
||||||
wheel,
|
|
||||||
django,
|
|
||||||
}:
|
|
||||||
|
|
||||||
buildPythonPackage rec {
|
|
||||||
pname = "django-xforwardedfor-middleware";
|
|
||||||
version = "2.0";
|
|
||||||
pyproject = true;
|
|
||||||
|
|
||||||
src = fetchFromGitHub {
|
|
||||||
owner = "allo-";
|
|
||||||
repo = "django-xforwardedfor-middleware";
|
|
||||||
rev = "v${version}";
|
|
||||||
hash = "sha256-dDXSb17kXOSeIgY6wid1QFHhUjrapasWgCEb/El51eA=";
|
|
||||||
};
|
|
||||||
|
|
||||||
build-system = [
|
|
||||||
setuptools
|
|
||||||
wheel
|
|
||||||
];
|
|
||||||
|
|
||||||
dependencies = [ django ];
|
|
||||||
|
|
||||||
pythonImportsCheck = [ "x_forwarded_for" ];
|
|
||||||
|
|
||||||
meta = {
|
|
||||||
description = "Use the X-Forwarded-For header to get the real ip of a request";
|
|
||||||
homepage = "https://github.com/allo-/django-xforwardedfor-middleware";
|
|
||||||
license = lib.licenses.publicDomain;
|
|
||||||
maintainers = with lib.maintainers; [ ];
|
|
||||||
};
|
|
||||||
}
|
|
||||||
@@ -1,74 +0,0 @@
|
|||||||
{
|
|
||||||
lib,
|
|
||||||
buildPythonPackage,
|
|
||||||
fetchFromGitHub,
|
|
||||||
setuptools,
|
|
||||||
setuptools-scm,
|
|
||||||
wheel,
|
|
||||||
prettytable,
|
|
||||||
tomli,
|
|
||||||
autopep8,
|
|
||||||
black,
|
|
||||||
docutils,
|
|
||||||
isort,
|
|
||||||
mypy,
|
|
||||||
pip-tools,
|
|
||||||
pypandoc,
|
|
||||||
pytest-cov,
|
|
||||||
pytest-pycodestyle,
|
|
||||||
pytestrunner,
|
|
||||||
tomli-w,
|
|
||||||
twine,
|
|
||||||
}:
|
|
||||||
|
|
||||||
buildPythonPackage rec {
|
|
||||||
pname = "pip-licenses";
|
|
||||||
version = "5.0.0";
|
|
||||||
pyproject = true;
|
|
||||||
|
|
||||||
src = fetchFromGitHub {
|
|
||||||
owner = "raimon49";
|
|
||||||
repo = "pip-licenses";
|
|
||||||
rev = "v-${version}";
|
|
||||||
hash = "sha256-6xw6BCuXSzNcwkpHaEFC5UPpubPUwhx/pg6vZq2er7A=";
|
|
||||||
};
|
|
||||||
|
|
||||||
build-system = [
|
|
||||||
setuptools
|
|
||||||
setuptools-scm
|
|
||||||
wheel
|
|
||||||
];
|
|
||||||
|
|
||||||
dependencies = [
|
|
||||||
prettytable
|
|
||||||
tomli
|
|
||||||
];
|
|
||||||
|
|
||||||
optional-dependencies = {
|
|
||||||
dev = [
|
|
||||||
autopep8
|
|
||||||
black
|
|
||||||
docutils
|
|
||||||
isort
|
|
||||||
mypy
|
|
||||||
pip-tools
|
|
||||||
pypandoc
|
|
||||||
pytest-cov
|
|
||||||
pytest-pycodestyle
|
|
||||||
pytestrunner
|
|
||||||
tomli-w
|
|
||||||
twine
|
|
||||||
wheel
|
|
||||||
];
|
|
||||||
};
|
|
||||||
|
|
||||||
pythonImportsCheck = [ "piplicenses" ];
|
|
||||||
|
|
||||||
meta = {
|
|
||||||
description = "Dump the license list of packages installed with pip";
|
|
||||||
homepage = "https://github.com/raimon49/pip-licenses";
|
|
||||||
changelog = "https://github.com/raimon49/pip-licenses/blob/${src.rev}/CHANGELOG.md";
|
|
||||||
license = lib.licenses.mit;
|
|
||||||
maintainers = with lib.maintainers; [ ];
|
|
||||||
};
|
|
||||||
}
|
|
||||||
@@ -1,42 +0,0 @@
|
|||||||
{
|
|
||||||
lib,
|
|
||||||
buildPythonPackage,
|
|
||||||
fetchFromGitHub,
|
|
||||||
setuptools,
|
|
||||||
wheel,
|
|
||||||
babel,
|
|
||||||
typing-extensions,
|
|
||||||
}:
|
|
||||||
|
|
||||||
buildPythonPackage rec {
|
|
||||||
pname = "py-moneyed";
|
|
||||||
version = "3.0";
|
|
||||||
pyproject = true;
|
|
||||||
|
|
||||||
src = fetchFromGitHub {
|
|
||||||
owner = "py-moneyed";
|
|
||||||
repo = "py-moneyed";
|
|
||||||
rev = "v${version}";
|
|
||||||
hash = "sha256-k0ZbLwog6TYxKDLZV7eH1Br8buMPfpOkgp+pMN/qdB8=";
|
|
||||||
};
|
|
||||||
|
|
||||||
build-system = [
|
|
||||||
setuptools
|
|
||||||
wheel
|
|
||||||
];
|
|
||||||
|
|
||||||
dependencies = [
|
|
||||||
babel
|
|
||||||
typing-extensions
|
|
||||||
];
|
|
||||||
|
|
||||||
pythonImportsCheck = [ "moneyed" ];
|
|
||||||
|
|
||||||
meta = {
|
|
||||||
description = "Provides Currency and Money classes for use in your Python code";
|
|
||||||
homepage = "http://github.com/py-moneyed/py-moneyed";
|
|
||||||
changelog = "https://github.com/py-moneyed/py-moneyed/blob/${src.rev}/CHANGES.rst";
|
|
||||||
license = lib.licenses.bsd3;
|
|
||||||
maintainers = with lib.maintainers; [ ];
|
|
||||||
};
|
|
||||||
}
|
|
||||||
@@ -1,43 +0,0 @@
|
|||||||
{
|
|
||||||
lib,
|
|
||||||
buildPythonPackage,
|
|
||||||
fetchFromGitHub,
|
|
||||||
setuptools,
|
|
||||||
wheel,
|
|
||||||
certifi,
|
|
||||||
urllib3,
|
|
||||||
}:
|
|
||||||
|
|
||||||
buildPythonPackage rec {
|
|
||||||
pname = "sentry-sdk";
|
|
||||||
version = "2.26.1";
|
|
||||||
pyproject = true;
|
|
||||||
|
|
||||||
src = fetchFromGitHub {
|
|
||||||
owner = "getsentry";
|
|
||||||
repo = "sentry-python";
|
|
||||||
rev = version;
|
|
||||||
hash = "sha256-Wl8yq2X9GuPcqaS93hkKXs2cDzz282Xceaai4NjbVZY=";
|
|
||||||
fetchSubmodules = true;
|
|
||||||
};
|
|
||||||
|
|
||||||
build-system = [
|
|
||||||
setuptools
|
|
||||||
wheel
|
|
||||||
];
|
|
||||||
|
|
||||||
dependencies = [
|
|
||||||
certifi
|
|
||||||
urllib3
|
|
||||||
];
|
|
||||||
|
|
||||||
pythonImportsCheck = [ "sentry_sdk" ];
|
|
||||||
|
|
||||||
meta = {
|
|
||||||
description = "The official Python SDK for Sentry.io";
|
|
||||||
homepage = "https://github.com/getsentry/sentry-python";
|
|
||||||
changelog = "https://github.com/getsentry/sentry-python/blob/${src.rev}/CHANGELOG.md";
|
|
||||||
license = lib.licenses.mit;
|
|
||||||
maintainers = with lib.maintainers; [ ];
|
|
||||||
};
|
|
||||||
}
|
|
||||||
Reference in New Issue
Block a user