Merge branch 'staging/nixpkgs-2023-05-18'
This commit is contained in:
commit
3aa1a9f674
12
flake.lock
12
flake.lock
|
@ -36,11 +36,11 @@
|
||||||
"nixpkgs": "nixpkgs"
|
"nixpkgs": "nixpkgs"
|
||||||
},
|
},
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1678202930,
|
"lastModified": 1684319086,
|
||||||
"narHash": "sha256-SF82/tTnagdazlETJLzXD9kjZ6lyk38agdLbmMx1UZE=",
|
"narHash": "sha256-5wwlkWqP1cQUPXp/PJsi09FkgAule5yBghngRZZbUQg=",
|
||||||
"owner": "edolstra",
|
"owner": "edolstra",
|
||||||
"repo": "nix-serve",
|
"repo": "nix-serve",
|
||||||
"rev": "3b6d30016d910a43e0e16f94170440a3e0b8fa8d",
|
"rev": "e6e3d09438e803daa5374ad8edf1271289348456",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
|
@ -82,11 +82,11 @@
|
||||||
},
|
},
|
||||||
"nixpkgs-unpatched": {
|
"nixpkgs-unpatched": {
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1684049129,
|
"lastModified": 1684385584,
|
||||||
"narHash": "sha256-7WB9LpnPNAS8oI7hMoHeKLNhRX7k3CI9uWBRSfmOCCE=",
|
"narHash": "sha256-O7y0gK8OLIDqz+LaHJJyeu09IGiXlZIS3+JgEzGmmJA=",
|
||||||
"owner": "nixos",
|
"owner": "nixos",
|
||||||
"repo": "nixpkgs",
|
"repo": "nixpkgs",
|
||||||
"rev": "0470f36b02ef01d4f43c641bbf07020bcab71bf1",
|
"rev": "48a0fb7aab511df92a17cf239c37f2bd2ec9ae3a",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
|
|
|
@ -36,11 +36,9 @@
|
||||||
services.snapper.configs.nix = {
|
services.snapper.configs.nix = {
|
||||||
# TODO: for the impermanent setup, we'd prefer to just do /nix/persist,
|
# TODO: for the impermanent setup, we'd prefer to just do /nix/persist,
|
||||||
# but that also requires setting up the persist dir as a subvol
|
# but that also requires setting up the persist dir as a subvol
|
||||||
subvolume = "/nix";
|
SUBVOLUME = "/nix";
|
||||||
# TODO: ALLOW_USERS doesn't seem to work. still need `sudo snapper -c nix list`
|
# TODO: ALLOW_USERS doesn't seem to work. still need `sudo snapper -c nix list`
|
||||||
extraConfig = ''
|
ALLOW_USERS = [ "colin" ];
|
||||||
ALLOW_USERS = "colin";
|
|
||||||
'';
|
|
||||||
};
|
};
|
||||||
|
|
||||||
programs.steam = {
|
programs.steam = {
|
||||||
|
|
|
@ -29,7 +29,8 @@
|
||||||
services.snapper.configs.nix = {
|
services.snapper.configs.nix = {
|
||||||
# TODO: for the impermanent setup, we'd prefer to just do /nix/persist,
|
# TODO: for the impermanent setup, we'd prefer to just do /nix/persist,
|
||||||
# but that also requires setting up the persist dir as a subvol
|
# but that also requires setting up the persist dir as a subvol
|
||||||
subvolume = "/nix";
|
SUBVOLUME = "/nix";
|
||||||
|
ALLOW_USERS = [ "colin" ];
|
||||||
};
|
};
|
||||||
|
|
||||||
# TODO: only here for debugging
|
# TODO: only here for debugging
|
||||||
|
|
|
@ -68,13 +68,6 @@ in [
|
||||||
hash = "sha256-Z1HOps3w/WvxAiyUAHWszKqwS9EwA6rf4XfgPGp+2sQ=";
|
hash = "sha256-Z1HOps3w/WvxAiyUAHWszKqwS9EwA6rf4XfgPGp+2sQ=";
|
||||||
})
|
})
|
||||||
|
|
||||||
(fetchpatch' {
|
|
||||||
# kiwix-tools: 3.4.0 -> 3.5.0
|
|
||||||
saneCommit = "146f2449a19101ee202aa578a2b1d7377779890b";
|
|
||||||
prUrl = "https://github.com/NixOS/nixpkgs/pull/232020";
|
|
||||||
hash = "sha256-Tqr8Ri8X2dDljDmWmjAQDRJGNenSFhrY/wr24h2JAh0=";
|
|
||||||
})
|
|
||||||
|
|
||||||
(fetchpatch' {
|
(fetchpatch' {
|
||||||
# nixos/lemmy: support nginx
|
# nixos/lemmy: support nginx
|
||||||
saneCommit = "4c86db6dcb78795ac9bb514d9c779fd591070b23";
|
saneCommit = "4c86db6dcb78795ac9bb514d9c779fd591070b23";
|
||||||
|
|
|
@ -27,7 +27,6 @@ let
|
||||||
"bin"
|
"bin"
|
||||||
coreutils-full
|
coreutils-full
|
||||||
curl
|
curl
|
||||||
duplicity
|
|
||||||
file
|
file
|
||||||
findutils
|
findutils
|
||||||
git
|
git
|
||||||
|
@ -49,12 +48,10 @@ let
|
||||||
sops
|
sops
|
||||||
sudo
|
sudo
|
||||||
systemd
|
systemd
|
||||||
transmission
|
|
||||||
util-linux
|
util-linux
|
||||||
which
|
which
|
||||||
];
|
];
|
||||||
keep = {
|
keep = {
|
||||||
"/run/secrets/duplicity_passphrase" = true;
|
|
||||||
# we write here: keep it
|
# we write here: keep it
|
||||||
"/tmp/rmlint.sh" = true;
|
"/tmp/rmlint.sh" = true;
|
||||||
# intentionally escapes (into user code)
|
# intentionally escapes (into user code)
|
||||||
|
@ -78,7 +75,6 @@ let
|
||||||
|
|
||||||
# list of programs which *can* or *cannot* exec their arguments
|
# list of programs which *can* or *cannot* exec their arguments
|
||||||
execer = with pkgs; [
|
execer = with pkgs; [
|
||||||
"cannot:${duplicity}/bin/duplicity"
|
|
||||||
"cannot:${git}/bin/git"
|
"cannot:${git}/bin/git"
|
||||||
"cannot:${gocryptfs}/bin/gocryptfs"
|
"cannot:${gocryptfs}/bin/gocryptfs"
|
||||||
"cannot:${ifuse}/bin/ifuse"
|
"cannot:${ifuse}/bin/ifuse"
|
||||||
|
@ -90,7 +86,6 @@ let
|
||||||
"cannot:${sops}/bin/sops"
|
"cannot:${sops}/bin/sops"
|
||||||
"cannot:${ssh-to-age}/bin/ssh-to-age"
|
"cannot:${ssh-to-age}/bin/ssh-to-age"
|
||||||
"cannot:${systemd}/bin/systemctl"
|
"cannot:${systemd}/bin/systemctl"
|
||||||
"cannot:${transmission}/bin/transmission-remote"
|
|
||||||
];
|
];
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
@ -108,14 +103,34 @@ let
|
||||||
};
|
};
|
||||||
|
|
||||||
py-scripts = {
|
py-scripts = {
|
||||||
# anything added to this attrset gets symlink-joined into into `sane-scripts`
|
# anything added to this attrset gets symlink-joined into `sane-scripts`
|
||||||
|
backup-ls = static-nix-shell.mkBash {
|
||||||
|
pname = "sane-backup-ls";
|
||||||
|
src = ./src;
|
||||||
|
pkgs = [ "duplicity" ];
|
||||||
|
};
|
||||||
|
backup-restore = static-nix-shell.mkBash {
|
||||||
|
pname = "sane-backup-restore";
|
||||||
|
src = ./src;
|
||||||
|
pkgs = [ "duplicity" ];
|
||||||
|
};
|
||||||
|
bt-add = static-nix-shell.mkBash {
|
||||||
|
pname = "sane-bt-add";
|
||||||
|
src = ./src;
|
||||||
|
pkgs = [ "transmission" ];
|
||||||
|
};
|
||||||
|
bt-rm = static-nix-shell.mkBash {
|
||||||
|
pname = "sane-bt-rm";
|
||||||
|
src = ./src;
|
||||||
|
pkgs = [ "transmission" ];
|
||||||
|
};
|
||||||
bt-search = static-nix-shell.mkPython3Bin {
|
bt-search = static-nix-shell.mkPython3Bin {
|
||||||
pname = "sane-bt-search";
|
pname = "sane-bt-search";
|
||||||
src = ./src;
|
src = ./src;
|
||||||
pyPkgs = [ "natsort" "requests" ];
|
pyPkgs = [ "natsort" "requests" ];
|
||||||
};
|
};
|
||||||
bt-rm = static-nix-shell.mkBash {
|
bt-show = static-nix-shell.mkBash {
|
||||||
pname = "sane-bt-rm";
|
pname = "sane-bt-show";
|
||||||
src = ./src;
|
src = ./src;
|
||||||
pkgs = [ "transmission" ];
|
pkgs = [ "transmission" ];
|
||||||
};
|
};
|
||||||
|
|
|
@ -1,10 +1,11 @@
|
||||||
#!/usr/bin/env bash
|
#!/usr/bin/env nix-shell
|
||||||
|
#!nix-shell -i bash -p duplicity
|
||||||
|
|
||||||
# N.B. must be run as root
|
# N.B. must be run as root
|
||||||
|
|
||||||
set -ex
|
set -ex
|
||||||
|
|
||||||
# source the URL; hack to satisfy resholve
|
# source the URL; hack to satisfy resholve
|
||||||
external_cmd="source /run/secrets/duplicity_passphrase"
|
external_cmd="source /run/secrets/duplicity_passphrase.env"
|
||||||
$external_cmd
|
$external_cmd
|
||||||
duplicity list-current-files --archive-dir /var/lib/duplicity $DUPLICITY_URL
|
duplicity list-current-files --archive-dir /var/lib/duplicity $DUPLICITY_URL
|
||||||
|
|
|
@ -1,4 +1,5 @@
|
||||||
#!/usr/bin/env bash
|
#!/usr/bin/env nix-shell
|
||||||
|
#!nix-shell -i bash -p duplicity
|
||||||
|
|
||||||
# N.B. must be run as root
|
# N.B. must be run as root
|
||||||
|
|
||||||
|
@ -8,6 +9,6 @@ dest_path="$1"
|
||||||
source_path="$2"
|
source_path="$2"
|
||||||
|
|
||||||
# source the URL; hack to satisfy resholve
|
# source the URL; hack to satisfy resholve
|
||||||
external_cmd="source /run/secrets/duplicity_passphrase"
|
external_cmd="source /run/secrets/duplicity_passphrase.env"
|
||||||
$external_cmd
|
$external_cmd
|
||||||
duplicity restore --archive-dir /var/lib/duplicity --file-to-restore "$source_path" $DUPLICITY_URL "$dest_path"
|
duplicity restore --archive-dir /var/lib/duplicity --file-to-restore "$source_path" $DUPLICITY_URL "$dest_path"
|
||||||
|
|
|
@ -1,11 +1,12 @@
|
||||||
#!/usr/bin/env bash
|
#!/usr/bin/env nix-shell
|
||||||
|
#!nix-shell -i bash -p transmission
|
||||||
|
|
||||||
set -e
|
set -e
|
||||||
|
|
||||||
endpoint=https://bt.uninsane.org/transmission/rpc
|
endpoint=https://bt.uninsane.org/transmission/rpc
|
||||||
PASS=$(sudo cat /run/secrets/transmission_passwd)
|
PASS=$(sudo cat /run/secrets/transmission_passwd)
|
||||||
|
|
||||||
options=$(getopt -l prefix:,film,show:,book:,audiobook:,vn:,author: -- "" "${@}")
|
options=$(getopt -l help,prefix:,film,show:,book:,audiobook:,vn:,author: -- "" "${@}")
|
||||||
eval "set -- ${options}"
|
eval "set -- ${options}"
|
||||||
|
|
||||||
type=
|
type=
|
||||||
|
@ -14,6 +15,22 @@ author=
|
||||||
prefix=
|
prefix=
|
||||||
while true; do
|
while true; do
|
||||||
case "$1" in
|
case "$1" in
|
||||||
|
(--help)
|
||||||
|
echo "add a .torrent or magnet:// file to be downloaded by and stored on my server"
|
||||||
|
echo "usage: sane-bt-add [options] <magnet:// URI or path/to.torrent>"
|
||||||
|
echo "options:"
|
||||||
|
echo " --prefix <PathString>"
|
||||||
|
echo " --film"
|
||||||
|
echo " --show <ShowTitle>"
|
||||||
|
echo " --book <BookTitle>"
|
||||||
|
echo " --audiobook <BookTitle>"
|
||||||
|
echo " --vn <VisualNovelTitle>"
|
||||||
|
echo " --author <Author>"
|
||||||
|
echo ""
|
||||||
|
echo "the above options are used to construct the filesystem path where the torrent data will live"
|
||||||
|
echo "everything is relative to the root media directory (not /)"
|
||||||
|
exit
|
||||||
|
;;
|
||||||
(--prefix)
|
(--prefix)
|
||||||
shift
|
shift
|
||||||
prefix="$1"
|
prefix="$1"
|
||||||
|
|
|
@ -1,4 +1,5 @@
|
||||||
#!/usr/bin/env bash
|
#!/usr/bin/env nix-shell
|
||||||
|
#!nix-shell -i bash -p transmission
|
||||||
|
|
||||||
endpoint=https://bt.uninsane.org/transmission/rpc
|
endpoint=https://bt.uninsane.org/transmission/rpc
|
||||||
PASS=$(sudo cat /run/secrets/transmission_passwd)
|
PASS=$(sudo cat /run/secrets/transmission_passwd)
|
||||||
|
|
Loading…
Reference in New Issue
Block a user