Compare commits
2 commits
d8f90dd940
...
0559e91c9c
Author | SHA1 | Date | |
---|---|---|---|
|
0559e91c9c | ||
d29374214b |
4 changed files with 105 additions and 38 deletions
|
@ -13,7 +13,7 @@ in
|
|||
services = {
|
||||
netbox = {
|
||||
enable = true;
|
||||
package = nixpkgs.unstable.netbox_3_7;
|
||||
package = nixpkgs.unstable.netbox_4_1;
|
||||
secretKeyFile = "/dev/null";
|
||||
listenAddress = "127.0.0.1";
|
||||
plugins = p: [ p.netbox-qrcode ];
|
||||
|
|
|
@ -59,10 +59,10 @@
|
|||
"pre_releases": false,
|
||||
"version_upper_bound": null,
|
||||
"release_prefix": null,
|
||||
"version": "v1.8.2",
|
||||
"revision": "0a97c6683ecb8d92ab0ce4c3c39e896e4a3fe388",
|
||||
"url": "https://api.github.com/repos/nix-community/disko/tarball/v1.8.2",
|
||||
"hash": "1xivgibk1fa07z4xqxpyha6yyb0pmahf52caf1kgh8zxr231ai1v"
|
||||
"version": "v1.9.0",
|
||||
"revision": "49a4936cee640e27d74baee6fd1278285d29b100",
|
||||
"url": "https://api.github.com/repos/nix-community/disko/tarball/v1.9.0",
|
||||
"hash": "0j76ar4qz320fakdii4659w5lww8wiz6yb7g47npywqvf2lbp388"
|
||||
},
|
||||
"dns.nix": {
|
||||
"type": "GitRelease",
|
||||
|
@ -87,9 +87,9 @@
|
|||
"repo": "git-hooks.nix"
|
||||
},
|
||||
"branch": "master",
|
||||
"revision": "3c3e88f0f544d6bb54329832616af7eb971b6be6",
|
||||
"url": "https://github.com/cachix/git-hooks.nix/archive/3c3e88f0f544d6bb54329832616af7eb971b6be6.tar.gz",
|
||||
"hash": "04pwjz423iq2nkazkys905gvsm5j39722ngavrnx42b8msr5k555"
|
||||
"revision": "d70155fdc00df4628446352fc58adc640cd705c2",
|
||||
"url": "https://github.com/cachix/git-hooks.nix/archive/d70155fdc00df4628446352fc58adc640cd705c2.tar.gz",
|
||||
"hash": "1s4w7bnign9lfzm8bm9j0zkvqfh5f1x671jp4g61psq42v5cfqvx"
|
||||
},
|
||||
"kadenios": {
|
||||
"type": "Git",
|
||||
|
@ -144,9 +144,9 @@
|
|||
"url": "https://git.lix.systems/lix-project/lix.git"
|
||||
},
|
||||
"branch": "main",
|
||||
"revision": "0ff8f9132552e03497b07e1e5c068660a7a04515",
|
||||
"revision": "d1d96cc4c8bd661a65c6159039a9d7e7e8fdf771",
|
||||
"url": null,
|
||||
"hash": "0qdaiqp5q2nb0yffc03vhlbd55v1jk3jlxz26prhk0hxddz0xhyq"
|
||||
"hash": "14yr9ivpd2xx5dw81sjnsv2m7adqjmm5sxxckh5wzjw6mi3gbjs4"
|
||||
},
|
||||
"lix-module": {
|
||||
"type": "Git",
|
||||
|
@ -155,9 +155,9 @@
|
|||
"url": "https://git.lix.systems/lix-project/nixos-module.git"
|
||||
},
|
||||
"branch": "main",
|
||||
"revision": "fd186f535a4ac7ae35d98c1dd5d79f0a81b7976d",
|
||||
"revision": "691193879d96bdfd1e6ab5ebcca2fadc7604cf34",
|
||||
"url": null,
|
||||
"hash": "0jxpqaz12lqibg03iv36sa0shfvamn2yhg937llv3kl4csijd34f"
|
||||
"hash": "1h4f2p6x8vq7bfc20hxk6zz9i4imsjjkmf0m28bzmx6vinxqimj4"
|
||||
},
|
||||
"lon": {
|
||||
"type": "Git",
|
||||
|
@ -201,9 +201,9 @@
|
|||
"url": "https://git.hubrecht.ovh/hubrecht/nix-modules.git"
|
||||
},
|
||||
"branch": "main",
|
||||
"revision": "516225dc6958645284b11b74b9ce31e01993341c",
|
||||
"revision": "662c5c6a78fb656be70be458ac9864def77a6dac",
|
||||
"url": null,
|
||||
"hash": "1cxn1m1xf9p7p8a0y8r6iwp08d886k5rmgl947r9d0vg7ah31kmj"
|
||||
"hash": "0szvbh1djd5fnkrfba7yc44q8sdxwyrn9r729j5lnyyd1rxj0dw6"
|
||||
},
|
||||
"nix-patches": {
|
||||
"type": "GitRelease",
|
||||
|
@ -226,15 +226,15 @@
|
|||
"url": "https://git.hubrecht.ovh/hubrecht/nix-pkgs"
|
||||
},
|
||||
"branch": "main",
|
||||
"revision": "e3fac77b062c9fe98dc1b5a367b0a8e70cde9624",
|
||||
"revision": "4ef413bdaccdf215ce35d99fc2909fbc26eb3d83",
|
||||
"url": null,
|
||||
"hash": "12xqh19mv8zgvyrh4vfnc95acf45x81g398pyqsd1xy1l7030r7i"
|
||||
"hash": "1izrbhj3yx56ml2p39fi004p4k7253yi0lcvfww9b8n8f96m1a1q"
|
||||
},
|
||||
"nixos-24.05": {
|
||||
"type": "Channel",
|
||||
"name": "nixos-24.05",
|
||||
"url": "https://releases.nixos.org/nixos/24.05/nixos-24.05.5809.4eb33fe664af/nixexprs.tar.xz",
|
||||
"hash": "02hxkkrpf33s6nsqkla1292zw64dqfq9wpkda5hry3vr3fhxwwg4"
|
||||
"url": "https://releases.nixos.org/nixos/24.05/nixos-24.05.6463.83fb6c028368/nixexprs.tar.xz",
|
||||
"hash": "1h73z8c0fp8sh9wvh80gyv99hncnzzdrah65lyb5f47z3w2hqiqc"
|
||||
},
|
||||
"nixos-generators": {
|
||||
"type": "Git",
|
||||
|
@ -244,21 +244,21 @@
|
|||
"repo": "nixos-generators"
|
||||
},
|
||||
"branch": "master",
|
||||
"revision": "dd28a0806e7124fe392c33c9ccaa12f21970401f",
|
||||
"url": "https://github.com/nix-community/nixos-generators/archive/dd28a0806e7124fe392c33c9ccaa12f21970401f.tar.gz",
|
||||
"hash": "09226kqddjg1m8m1q9n4l1hsln93hckhj238q0v851wxbwd0qq73"
|
||||
"revision": "7c60ba4bc8d6aa2ba3e5b0f6ceb9fc07bc261565",
|
||||
"url": "https://github.com/nix-community/nixos-generators/archive/7c60ba4bc8d6aa2ba3e5b0f6ceb9fc07bc261565.tar.gz",
|
||||
"hash": "0n0nx4d68qyn2d5kvg8g3dczr1l9aq0k91hlvg4dw15rg0ycppdk"
|
||||
},
|
||||
"nixos-unstable": {
|
||||
"type": "Channel",
|
||||
"name": "nixos-unstable",
|
||||
"url": "https://releases.nixos.org/nixos/unstable/nixos-24.11pre694395.4c2fcb090b1f/nixexprs.tar.xz",
|
||||
"hash": "05fszj13lci5gdbn5grn92wd3mzj6f7gy11kqj78xcsg69m2wbrl"
|
||||
"url": "https://releases.nixos.org/nixos/unstable/nixos-24.11pre703931.4aa36568d413/nixexprs.tar.xz",
|
||||
"hash": "1z0ljvlgqcrrm62wzp44lr0qlxy43xxn6q0wf7pb3hzxx5546bb3"
|
||||
},
|
||||
"nixpkgs": {
|
||||
"type": "Channel",
|
||||
"name": "nixpkgs-unstable",
|
||||
"url": "https://releases.nixos.org/nixpkgs/nixpkgs-24.11pre694416.ccc0c2126893/nixexprs.tar.xz",
|
||||
"hash": "0cn1z4wzps8nfqxzr6l5mbn81adcqy2cy2ic70z13fhzicmxfsbx"
|
||||
"url": "https://releases.nixos.org/nixpkgs/nixpkgs-24.11pre704822.85f7e662eda4/nixexprs.tar.xz",
|
||||
"hash": "0dqlz0xqd3nn49hnx943y5sfqd7nmj25s6gi1pjm907j3vbgg47k"
|
||||
},
|
||||
"proxmox-nixos": {
|
||||
"type": "Git",
|
||||
|
@ -268,9 +268,9 @@
|
|||
"repo": "proxmox-nixos"
|
||||
},
|
||||
"branch": "main",
|
||||
"revision": "950e4cccac0f942076e8558f7f9f4d496cabfb18",
|
||||
"url": "https://github.com/SaumonNet/proxmox-nixos/archive/950e4cccac0f942076e8558f7f9f4d496cabfb18.tar.gz",
|
||||
"hash": "0bhqw42ydc0jfkfqw64xsg518a1pbxnvpqw92nna7lm8mzpxm6d4"
|
||||
"revision": "93880e244b528deca89828bc1edf08e23ccc18c4",
|
||||
"url": "https://github.com/SaumonNet/proxmox-nixos/archive/93880e244b528deca89828bc1edf08e23ccc18c4.tar.gz",
|
||||
"hash": "0dyiv7mvvxc0zygfzfb6zhc0v3s7a9pv8xydprxgqhyy1sajp02h"
|
||||
},
|
||||
"signal-irc-bridge": {
|
||||
"type": "Git",
|
||||
|
@ -302,9 +302,9 @@
|
|||
"server": "https://git.helsinki.tools/"
|
||||
},
|
||||
"branch": "master",
|
||||
"revision": "f72adfc39c18630b45f8c982910314246d4a8d92",
|
||||
"url": "https://git.helsinki.tools/api/v4/projects/helsinki-systems%2Fwp4nix/repository/archive.tar.gz?sha=f72adfc39c18630b45f8c982910314246d4a8d92",
|
||||
"hash": "08qfaav3vb832dr3r6f2n1ah6zyryvab0dxsaxwi6gk5p3zad3l8"
|
||||
"revision": "14dfb7590c74a67d93651492100ba2bf66d064af",
|
||||
"url": "https://git.helsinki.tools/api/v4/projects/helsinki-systems%2Fwp4nix/repository/archive.tar.gz?sha=14dfb7590c74a67d93651492100ba2bf66d064af",
|
||||
"hash": "04qyjqvi2f930yiss32ym24hknfyimlyvhc97r71hprz26y2yh42"
|
||||
}
|
||||
},
|
||||
"version": 3
|
||||
|
|
70
patches/06-netbox-qrcode.patch
Normal file
70
patches/06-netbox-qrcode.patch
Normal file
|
@ -0,0 +1,70 @@
|
|||
diff --git a/pkgs/development/python-modules/netbox-qrcode/default.nix b/pkgs/development/python-modules/netbox-qrcode/default.nix
|
||||
new file mode 100644
|
||||
index 000000000000..b378b839a8dc
|
||||
--- /dev/null
|
||||
+++ b/pkgs/development/python-modules/netbox-qrcode/default.nix
|
||||
@@ -0,0 +1,51 @@
|
||||
+{ lib
|
||||
+, buildPythonPackage
|
||||
+, fetchFromGitHub
|
||||
+, setuptools
|
||||
+, wheel
|
||||
+, pillow
|
||||
+, qrcode
|
||||
+, netbox
|
||||
+}:
|
||||
+
|
||||
+buildPythonPackage rec {
|
||||
+ pname = "netbox-qrcode";
|
||||
+ version = "0.0.13";
|
||||
+ pyproject = true;
|
||||
+
|
||||
+ src = fetchFromGitHub {
|
||||
+ owner = "netbox-community";
|
||||
+ repo = "netbox-qrcode";
|
||||
+ rev = "v${version}";
|
||||
+ hash = "sha256-/labSZyB1SkU/uemuL946RDk8IVEAgCYJY2vrJFney0=";
|
||||
+ };
|
||||
+
|
||||
+ nativeBuildInputs = [
|
||||
+ setuptools
|
||||
+ wheel
|
||||
+ ];
|
||||
+
|
||||
+ propagatedBuildInputs = [
|
||||
+ qrcode
|
||||
+ pillow
|
||||
+ ];
|
||||
+
|
||||
+ checkInputs = [
|
||||
+ netbox
|
||||
+ ];
|
||||
+
|
||||
+ preFixup = ''
|
||||
+ export PYTHONPATH=${netbox}/opt/netbox/netbox:$PYTHONPATH
|
||||
+ '';
|
||||
+
|
||||
+ pythonImportsCheck = [
|
||||
+ "netbox_qrcode"
|
||||
+ ];
|
||||
+
|
||||
+ meta = with lib; {
|
||||
+ description = "NetBox Plugin for generate QR Codes";
|
||||
+ homepage = "https://github.com/netbox-community/netbox-qrcode";
|
||||
+ license = licenses.asl20;
|
||||
+ maintainers = with maintainers; [ sinavir ];
|
||||
+ };
|
||||
+}
|
||||
diff --git a/pkgs/top-level/python-packages.nix b/pkgs/top-level/python-packages.nix
|
||||
index 9999d745e3ac..b226e0063672 100644
|
||||
--- a/pkgs/top-level/python-packages.nix
|
||||
+++ b/pkgs/top-level/python-packages.nix
|
||||
@@ -8989,6 +8989,8 @@ self: super: with self; {
|
||||
|
||||
netbox-reorder-rack = callPackage ../development/python-modules/netbox-reorder-rack { };
|
||||
|
||||
+ netbox-qrcode = callPackage ../development/python-modules/netbox-qrcode { };
|
||||
+
|
||||
netcdf4 = callPackage ../development/python-modules/netcdf4 { };
|
||||
|
||||
netdata = callPackage ../development/python-modules/netdata { };
|
|
@ -1,10 +1,8 @@
|
|||
{
|
||||
"nixos-24.05" = [
|
||||
# netbox qrcode plugin
|
||||
{
|
||||
_type = "commit";
|
||||
sha = "c82191d848e7a37e125ee15c485f32ac01afc0b2";
|
||||
hash = "sha256-TooktlqihtULzJJsHvm8EubbUdJZvbDKdIDcYu7Qcig=";
|
||||
_type = "static";
|
||||
path = ./06-netbox-qrcode.patch;
|
||||
}
|
||||
|
||||
# nixos/nextcloud: Rename autocreate (a no-op) to verify_bucket_exists
|
||||
|
@ -50,9 +48,8 @@
|
|||
"nixos-unstable" = [
|
||||
# netbox qrcode plugin
|
||||
{
|
||||
_type = "commit";
|
||||
sha = "c82191d848e7a37e125ee15c485f32ac01afc0b2";
|
||||
hash = "sha256-TooktlqihtULzJJsHvm8EubbUdJZvbDKdIDcYu7Qcig=";
|
||||
_type = "static";
|
||||
path = ./06-netbox-qrcode.patch;
|
||||
}
|
||||
|
||||
# Build netbird-relay
|
||||
|
|
Loading…
Reference in a new issue