Compare commits
2 commits
02dc7351ef
...
26df9abb22
Author | SHA1 | Date | |
---|---|---|---|
26df9abb22 | |||
9213c74e2a |
5 changed files with 16 additions and 11 deletions
|
@ -7,7 +7,7 @@ env:
|
||||||
ATTIC_TOKEN: ${{ secrets.ATTIC_TOKEN }}
|
ATTIC_TOKEN: ${{ secrets.ATTIC_TOKEN }}
|
||||||
NIX_CONFIG: |
|
NIX_CONFIG: |
|
||||||
show-trace = true
|
show-trace = true
|
||||||
extra-substituters = https://cache.cy7.sh/main
|
extra-substituters = https://cdn.cy7.sh/main
|
||||||
extra-trusted-public-keys = main:Ku31HoEWcBtfggge2VGj+QTkVrQuIwRIMGyfV/5VQP0=
|
extra-trusted-public-keys = main:Ku31HoEWcBtfggge2VGj+QTkVrQuIwRIMGyfV/5VQP0=
|
||||||
experimental-features = nix-command flakes
|
experimental-features = nix-command flakes
|
||||||
accept-flake-config = true
|
accept-flake-config = true
|
||||||
|
|
|
@ -107,7 +107,7 @@
|
||||||
nixConfig = {
|
nixConfig = {
|
||||||
extra-substituters = [
|
extra-substituters = [
|
||||||
"https://nix-community.cachix.org"
|
"https://nix-community.cachix.org"
|
||||||
"https://cache.cy7.sh/main"
|
"https://cdn.cy7.sh/main"
|
||||||
];
|
];
|
||||||
extra-trusted-public-keys = [
|
extra-trusted-public-keys = [
|
||||||
"nix-community.cachix.org-1:mB9FSh9qf2dCimDSUo8Zy7bkq5CX+/rkCWyvRCYg3Fs="
|
"nix-community.cachix.org-1:mB9FSh9qf2dCimDSUo8Zy7bkq5CX+/rkCWyvRCYg3Fs="
|
||||||
|
|
|
@ -44,15 +44,17 @@
|
||||||
--config ${config.sops.secrets."rclone/config".path} \
|
--config ${config.sops.secrets."rclone/config".path} \
|
||||||
--allow-other \
|
--allow-other \
|
||||||
--cache-dir /var/cache/rclone \
|
--cache-dir /var/cache/rclone \
|
||||||
--transfers=32 \
|
--transfers 32 \
|
||||||
--vfs-cache-mode full \
|
--vfs-cache-mode full \
|
||||||
--vfs-cache-min-free-space 5G \
|
--vfs-cache-min-free-space 5G \
|
||||||
--dir-cache-time 30d \
|
--dir-cache-time 30d \
|
||||||
--no-checksum \
|
--no-checksum \
|
||||||
--no-modtime \
|
--no-modtime \
|
||||||
--vfs-fast-fingerprint \
|
--vfs-fast-fingerprint \
|
||||||
--vfs-read-chunk-size 10M \
|
--vfs-read-chunk-size 4M \
|
||||||
--vfs-read-chunk-streams 32 \
|
--vfs-read-chunk-streams 64 \
|
||||||
|
--sftp-concurrency 128 \
|
||||||
|
--sftp-chunk-size 255k \
|
||||||
rsyncnet:garage /mnt/garage
|
rsyncnet:garage /mnt/garage
|
||||||
'';
|
'';
|
||||||
ExecStop = "${lib.getExe' pkgs.fuse "fusermount"} -u /mnt/garage";
|
ExecStop = "${lib.getExe' pkgs.fuse "fusermount"} -u /mnt/garage";
|
||||||
|
|
|
@ -15,7 +15,7 @@
|
||||||
];
|
];
|
||||||
extra-substituters = [
|
extra-substituters = [
|
||||||
"https://nix-community.cachix.org"
|
"https://nix-community.cachix.org"
|
||||||
"https://cache.cy7.sh/main"
|
"https://cdn.cy7.sh/main"
|
||||||
];
|
];
|
||||||
};
|
};
|
||||||
channel.enable = false;
|
channel.enable = false;
|
||||||
|
|
|
@ -18,7 +18,7 @@ in
|
||||||
settings = {
|
settings = {
|
||||||
listen = "[::]:8091";
|
listen = "[::]:8091";
|
||||||
api-endpoint = "https://cache.cy7.sh/";
|
api-endpoint = "https://cache.cy7.sh/";
|
||||||
allowed-hosts = [ "cache.cy7.sh" ];
|
allowed-hosts = [ "cache.cy7.sh" "cdn.cy7.sh" ];
|
||||||
require-proof-of-possession = false;
|
require-proof-of-possession = false;
|
||||||
compression = {
|
compression = {
|
||||||
type = "none";
|
type = "none";
|
||||||
|
@ -39,9 +39,12 @@ in
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
services.caddy.virtualHosts."cache.cy7.sh".extraConfig = ''
|
services.caddy.virtualHosts."cache.cy7.sh" = {
|
||||||
import common
|
serverAliases = [ "cdn.cy7.sh" ];
|
||||||
reverse_proxy localhost:8091
|
extraConfig = ''
|
||||||
'';
|
import common
|
||||||
|
reverse_proxy localhost:8091
|
||||||
|
'';
|
||||||
|
};
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue