Compare commits
No commits in common. "main" and "2025-04-07" have entirely different histories.
main
...
2025-04-07
16 changed files with 975 additions and 122 deletions
106
.github/workflows/build-machines-and-homes.yml
vendored
106
.github/workflows/build-machines-and-homes.yml
vendored
|
@ -8,8 +8,6 @@ env:
|
||||||
TERM: ansi
|
TERM: ansi
|
||||||
AWS_ACCESS_KEY_ID: ${{ secrets.AWS_ACCESS_KEY_ID }}
|
AWS_ACCESS_KEY_ID: ${{ secrets.AWS_ACCESS_KEY_ID }}
|
||||||
AWS_SECRET_ACCESS_KEY: ${{ secrets. AWS_SECRET_ACCESS_KEY }}
|
AWS_SECRET_ACCESS_KEY: ${{ secrets. AWS_SECRET_ACCESS_KEY }}
|
||||||
AWS_DEFAULT_REGION: us-east-1
|
|
||||||
AWS_ENDPOINT_URL: https://s3.cy7.sh
|
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
build-machines:
|
build-machines:
|
||||||
|
@ -37,26 +35,7 @@ jobs:
|
||||||
build-mount-path: /nix
|
build-mount-path: /nix
|
||||||
|
|
||||||
- name: setup binary cache key
|
- name: setup binary cache key
|
||||||
run: echo -n "${{ secrets.NIX_CACHE_SECRET_KEY }}" | xxd -p -r > ${{ runner.temp }}/cache-priv-key.pem
|
run: echo "${{ secrets.NIX_CACHE_SECRET_KEY }}" >> /home/runner/cache-priv-key.pem
|
||||||
|
|
||||||
- name: Sync repository
|
|
||||||
uses: actions/checkout@v4
|
|
||||||
with:
|
|
||||||
persist-credentials: false
|
|
||||||
|
|
||||||
- name: post-build-hook
|
|
||||||
run: |
|
|
||||||
sudo mkdir -p /etc/nix
|
|
||||||
sudo cp ci/upload-to-cache.sh /etc/nix/
|
|
||||||
sudo chmod +x /etc/nix/upload-to-cache.sh
|
|
||||||
|
|
||||||
- name: setup s3 credentials
|
|
||||||
run: |
|
|
||||||
sudo mkdir /root/.aws
|
|
||||||
echo "[default]" |sudo tee /root/.aws/config |sudo tee /root/.aws/credentials
|
|
||||||
echo "aws_access_key_id=$AWS_ACCESS_KEY_ID" |sudo tee -a /root/.aws/credentials
|
|
||||||
echo "aws_secret_access_key=$AWS_SECRET_ACCESS_KEY" |sudo tee -a /root/.aws/credentials
|
|
||||||
echo "endpoint_url=$AWS_ENDPOINT_URL" |sudo tee -a /root/.aws/config
|
|
||||||
|
|
||||||
- name: Install Nix
|
- name: Install Nix
|
||||||
uses: cachix/install-nix-action@v30
|
uses: cachix/install-nix-action@v30
|
||||||
|
@ -67,15 +46,39 @@ jobs:
|
||||||
experimental-features = nix-command flakes
|
experimental-features = nix-command flakes
|
||||||
accept-flake-config = true
|
accept-flake-config = true
|
||||||
system-features = nixos-test benchmark big-parallel kvm
|
system-features = nixos-test benchmark big-parallel kvm
|
||||||
secret-key-files = ${{ runner.temp }}/cache-priv-key.pem
|
secret-key-files = /home/runner/cache-priv-key.pem
|
||||||
extra-substituters = https://nixcache.cy7.sh
|
extra-substituters = https://nixcache.cy7.sh https://cache.lix.systems
|
||||||
extra-trusted-public-keys = nixcache.cy7.sh:DN3d1dt0wnXfTH03oVmTee4KgmdNdB0NY3SuzA8Fwx8=
|
extra-trusted-public-keys = nixcache.cy7.sh:DN3d1dt0wnXfTH03oVmTee4KgmdNdB0NY3SuzA8Fwx8= cache.lix.systems:aBnZUw8zA7H35Cz2RyKFVs3H4PlGTLawyY5KRbvJR8o=
|
||||||
post-build-hook = /etc/nix/upload-to-cache.sh
|
|
||||||
|
- name: Install Lix
|
||||||
|
run: |
|
||||||
|
sudo --preserve-env=PATH $(which nix) run \
|
||||||
|
'git+https://git.lix.systems/lix-project/lix?ref=refs/tags/2.92.0' -- \
|
||||||
|
upgrade-nix
|
||||||
|
nix --version
|
||||||
|
|
||||||
|
- name: Sync repository
|
||||||
|
uses: actions/checkout@v4
|
||||||
|
with:
|
||||||
|
persist-credentials: false
|
||||||
|
|
||||||
- name: build
|
- name: build
|
||||||
run: |
|
run: |
|
||||||
|
# package=".#nixosConfigurations."${{ matrix.machine }}".config.system.build.toplevel"
|
||||||
|
# nix build -L "$package"
|
||||||
nix run nixpkgs#nixos-rebuild build -- -L --flake ".#${{ matrix.machine }}"
|
nix run nixpkgs#nixos-rebuild build -- -L --flake ".#${{ matrix.machine }}"
|
||||||
|
|
||||||
|
- name: cache
|
||||||
|
# https://stackoverflow.com/a/58859404
|
||||||
|
if: '!cancelled()'
|
||||||
|
run: |
|
||||||
|
package=".#nixosConfigurations."${{ matrix.machine }}".config.system.build.toplevel"
|
||||||
|
nix run git+https://git.cy7.sh/cy/nixcp.git -- \
|
||||||
|
--to 's3://nixcache?endpoint=s3.cy7.sh&secret-key=/home/runner/cache-priv-key.pem&compression=zstd' \
|
||||||
|
-u https://nix-community.cachix.org \
|
||||||
|
-u https://nixcache.web.cy7.sh \
|
||||||
|
$package
|
||||||
|
|
||||||
build-homes:
|
build-homes:
|
||||||
strategy:
|
strategy:
|
||||||
fail-fast: false
|
fail-fast: false
|
||||||
|
@ -102,26 +105,7 @@ jobs:
|
||||||
build-mount-path: /nix
|
build-mount-path: /nix
|
||||||
|
|
||||||
- name: setup binary cache key
|
- name: setup binary cache key
|
||||||
run: echo -n "${{ secrets.NIX_CACHE_SECRET_KEY }}" | xxd -p -r > ${{ runner.temp }}/cache-priv-key.pem
|
run: echo "${{ secrets.NIX_CACHE_SECRET_KEY }}" >> /home/runner/cache-priv-key.pem
|
||||||
|
|
||||||
- name: Sync repository
|
|
||||||
uses: actions/checkout@v4
|
|
||||||
with:
|
|
||||||
persist-credentials: false
|
|
||||||
|
|
||||||
- name: post-build-hook
|
|
||||||
run: |
|
|
||||||
sudo mkdir -p /etc/nix
|
|
||||||
sudo cp ci/upload-to-cache.sh /etc/nix/
|
|
||||||
sudo chmod +x /etc/nix/upload-to-cache.sh
|
|
||||||
|
|
||||||
- name: setup s3 credentials
|
|
||||||
run: |
|
|
||||||
sudo mkdir /root/.aws
|
|
||||||
echo "[default]" |sudo tee /root/.aws/config |sudo tee /root/.aws/credentials
|
|
||||||
echo "aws_access_key_id=$AWS_ACCESS_KEY_ID" |sudo tee -a /root/.aws/credentials
|
|
||||||
echo "aws_secret_access_key=$AWS_SECRET_ACCESS_KEY" |sudo tee -a /root/.aws/credentials
|
|
||||||
echo "endpoint_url=$AWS_ENDPOINT_URL" |sudo tee -a /root/.aws/config
|
|
||||||
|
|
||||||
- name: Install Nix
|
- name: Install Nix
|
||||||
uses: cachix/install-nix-action@v30
|
uses: cachix/install-nix-action@v30
|
||||||
|
@ -132,12 +116,34 @@ jobs:
|
||||||
experimental-features = nix-command flakes
|
experimental-features = nix-command flakes
|
||||||
accept-flake-config = true
|
accept-flake-config = true
|
||||||
system-features = nixos-test benchmark big-parallel kvm
|
system-features = nixos-test benchmark big-parallel kvm
|
||||||
secret-key-files = ${{ runner.temp }}/cache-priv-key.pem
|
secret-key-files = /home/runner/cache-priv-key.pem
|
||||||
extra-substituters = https://nixcache.cy7.sh
|
extra-substituters = https://nixcache.cy7.sh https://cache.lix.systems
|
||||||
extra-trusted-public-keys = nixcache.cy7.sh:DN3d1dt0wnXfTH03oVmTee4KgmdNdB0NY3SuzA8Fwx8=
|
extra-trusted-public-keys = nixcache.cy7.sh:DN3d1dt0wnXfTH03oVmTee4KgmdNdB0NY3SuzA8Fwx8= cache.lix.systems:aBnZUw8zA7H35Cz2RyKFVs3H4PlGTLawyY5KRbvJR8o=
|
||||||
post-build-hook = /etc/nix/upload-to-cache.sh
|
|
||||||
|
- name: Install Lix
|
||||||
|
run: |
|
||||||
|
sudo --preserve-env=PATH $(which nix) run \
|
||||||
|
'git+https://git.lix.systems/lix-project/lix?ref=refs/tags/2.92.0' -- \
|
||||||
|
upgrade-nix
|
||||||
|
nix --version
|
||||||
|
|
||||||
|
- name: Sync repository
|
||||||
|
uses: actions/checkout@v4
|
||||||
|
with:
|
||||||
|
persist-credentials: false
|
||||||
|
|
||||||
- name: build
|
- name: build
|
||||||
run: |
|
run: |
|
||||||
package=".#homeConfigurations."${{ matrix.home }}".activationPackage"
|
package=".#homeConfigurations."${{ matrix.home }}".activationPackage"
|
||||||
nix build -L "$package"
|
nix build -L "$package"
|
||||||
|
|
||||||
|
- name: cache
|
||||||
|
# https://stackoverflow.com/a/58859404
|
||||||
|
if: '!cancelled()'
|
||||||
|
run: |
|
||||||
|
package=".#homeConfigurations."${{ matrix.home }}".activationPackage"
|
||||||
|
nix run git+https://git.cy7.sh/cy/nixcp.git -- \
|
||||||
|
--to 's3://nixcache?endpoint=s3.cy7.sh&secret-key=/home/runner/cache-priv-key.pem&compression=zstd' \
|
||||||
|
-u https://nix-community.cachix.org \
|
||||||
|
-u https://nixcache.web.cy7.sh \
|
||||||
|
$package
|
||||||
|
|
33
.github/workflows/build-packages.yml
vendored
33
.github/workflows/build-packages.yml
vendored
|
@ -11,8 +11,6 @@ env:
|
||||||
TERM: ansi
|
TERM: ansi
|
||||||
AWS_ACCESS_KEY_ID: ${{ secrets.AWS_ACCESS_KEY_ID }}
|
AWS_ACCESS_KEY_ID: ${{ secrets.AWS_ACCESS_KEY_ID }}
|
||||||
AWS_SECRET_ACCESS_KEY: ${{ secrets. AWS_SECRET_ACCESS_KEY }}
|
AWS_SECRET_ACCESS_KEY: ${{ secrets. AWS_SECRET_ACCESS_KEY }}
|
||||||
AWS_DEFAULT_REGION: us-east-1
|
|
||||||
AWS_ENDPOINT_URL: https://s3.cy7.sh
|
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
build-packages:
|
build-packages:
|
||||||
|
@ -24,13 +22,13 @@ jobs:
|
||||||
os:
|
os:
|
||||||
- ubuntu-latest
|
- ubuntu-latest
|
||||||
- ubuntu-24.04-arm
|
- ubuntu-24.04-arm
|
||||||
- macos-latest
|
# - macos-latest
|
||||||
- macos-13
|
# - macos-13
|
||||||
runs-on: ${{ matrix.os }}
|
runs-on: ${{ matrix.os }}
|
||||||
|
|
||||||
steps:
|
steps:
|
||||||
- name: setup binary cache key
|
- name: setup binary cache key
|
||||||
run: echo -n "${{ secrets.NIX_CACHE_SECRET_KEY }}" | xxd -p -r > ${{ runner.temp }}/cache-priv-key.pem
|
run: echo "${{ secrets.NIX_CACHE_SECRET_KEY }}" >> /home/runner/cache-priv-key.pem
|
||||||
|
|
||||||
- name: Install Nix
|
- name: Install Nix
|
||||||
uses: cachix/install-nix-action@v30
|
uses: cachix/install-nix-action@v30
|
||||||
|
@ -41,9 +39,21 @@ jobs:
|
||||||
experimental-features = nix-command flakes
|
experimental-features = nix-command flakes
|
||||||
accept-flake-config = true
|
accept-flake-config = true
|
||||||
system-features = nixos-test benchmark big-parallel kvm
|
system-features = nixos-test benchmark big-parallel kvm
|
||||||
secret-key-files = ${{ runner.temp }}/cache-priv-key.pem
|
secret-key-files = /home/runner/cache-priv-key.pem
|
||||||
extra-substituters = https://nixcache.cy7.sh
|
extra-substituters = https://nixcache.cy7.sh https://cache.lix.systems
|
||||||
extra-trusted-public-keys = nixcache.cy7.sh:DN3d1dt0wnXfTH03oVmTee4KgmdNdB0NY3SuzA8Fwx8=
|
extra-trusted-public-keys = nixcache.cy7.sh:DN3d1dt0wnXfTH03oVmTee4KgmdNdB0NY3SuzA8Fwx8= cache.lix.systems:aBnZUw8zA7H35Cz2RyKFVs3H4PlGTLawyY5KRbvJR8o=
|
||||||
|
|
||||||
|
- name: Install Lix
|
||||||
|
run: |
|
||||||
|
sudo --preserve-env=PATH $(which nix) run \
|
||||||
|
'git+https://git.lix.systems/lix-project/lix?ref=refs/tags/2.92.0' -- \
|
||||||
|
upgrade-nix
|
||||||
|
nix --version
|
||||||
|
|
||||||
|
- name: Sync repository
|
||||||
|
uses: actions/checkout@v4
|
||||||
|
with:
|
||||||
|
persist-credentials: false
|
||||||
|
|
||||||
- run: nix build -L ${{ matrix.package }}
|
- run: nix build -L ${{ matrix.package }}
|
||||||
|
|
||||||
|
@ -51,11 +61,10 @@ jobs:
|
||||||
# https://stackoverflow.com/a/58859404
|
# https://stackoverflow.com/a/58859404
|
||||||
if: '!cancelled()'
|
if: '!cancelled()'
|
||||||
run: |
|
run: |
|
||||||
nix run github:cything/nixcp -- \
|
nix run git+https://git.cy7.sh/cy/nixcp.git -- \
|
||||||
push \
|
--to 's3://nixcache?endpoint=s3.cy7.sh&secret-key=/home/runner/cache-priv-key.pem&compression=zstd' \
|
||||||
--bucket nixcache \
|
|
||||||
--signing-key ${{ runner.temp }}/cache-priv-key.pem \
|
|
||||||
-u https://nix-community.cachix.org \
|
-u https://nix-community.cachix.org \
|
||||||
|
-u https://nixcache.web.cy7.sh \
|
||||||
"${{ matrix.package }}"
|
"${{ matrix.package }}"
|
||||||
|
|
||||||
- name: prepare tarball to upload
|
- name: prepare tarball to upload
|
||||||
|
|
1
README
1
README
|
@ -1 +0,0 @@
|
||||||
this is only open source for free ci
|
|
40
README.md
Normal file
40
README.md
Normal file
|
@ -0,0 +1,40 @@
|
||||||
|
# infra
|
||||||
|
## ./home
|
||||||
|
- [home-manager](https://github.com/nix-community/home-manager) configuration files
|
||||||
|
- foot, tmux, and zsh are configured in Nix
|
||||||
|
- nvim, rofi, sway, waybar are configured in their own literature and symlinked to $XDG_CONFIG_HOME with home-manager
|
||||||
|
|
||||||
|
## ./hosts
|
||||||
|
- [`hosts/common.nix`](hosts/common.nix): configuration that makes sense on all computers
|
||||||
|
- [`hosts/zsh.nix`](hosts/zsh.nix): for computers that have the power to run zsh
|
||||||
|
### ./hosts/ytnix
|
||||||
|
- personal laptop
|
||||||
|
- a single [`default.nix`](hosts/ytnix/default.nix) that could be modularized but works for now
|
||||||
|
|
||||||
|
### ./hosts/chunk
|
||||||
|
- the overworked server with 5% SLA
|
||||||
|
- very short and concise [`default.nix`](hosts/chunk/default.nix)
|
||||||
|
- services organized in their modules
|
||||||
|
- some services run through `virtualisation.oci-containers`:
|
||||||
|
- [immich](hosts/chunk/immich.nix)
|
||||||
|
- [conduwuit](hosts/chunk/conduwuit.nix)
|
||||||
|
|
||||||
|
### ./hosts/titan
|
||||||
|
- got this cause chunk would go down way too often :(
|
||||||
|
- hosted on azure for "reliability"
|
||||||
|
- runs:
|
||||||
|
- [ghost](hosts/titan/ghost.nix) (through `virtualisation.oci-containers`)
|
||||||
|
- [uptime-kuma](hosts/titan/uptime-kuma.nix)
|
||||||
|
- [ntfy-sh](hosts/titan/ntfy.nix)
|
||||||
|
|
||||||
|
## ./secrets
|
||||||
|
- secrets
|
||||||
|
- see [`.sops.yaml`](.sops.yaml) for who privy to what
|
||||||
|
|
||||||
|
## backups
|
||||||
|
- hourly borgbackup to [rsync.net](https://rsync.net)
|
||||||
|
- see [modules/backup](modules/backup.nix)
|
||||||
|
|
||||||
|
## monitoring
|
||||||
|
- [status.cything.io](https://status.cything.io/): uptime kuma (reliable)
|
||||||
|
- [grafana.cything.io](https://grafana.cything.io/): some real-time metrics here; unlike the status page this will go kaput often
|
|
@ -1,8 +0,0 @@
|
||||||
#!/bin/sh
|
|
||||||
|
|
||||||
# https://nix.dev/guides/recipes/post-build-hook.html#implementing-the-build-hook
|
|
||||||
set -eu
|
|
||||||
set -f # disable globbing
|
|
||||||
export IFS=' '
|
|
||||||
echo "Uploading paths" $OUT_PATHS
|
|
||||||
exec /nix/var/nix/profiles/default/bin/nix copy --to "s3://nixcache?endpoint=s3.cy7.sh&compression=zstd¶llel-compression=true" $OUT_PATHS
|
|
844
flake.lock
generated
844
flake.lock
generated
File diff suppressed because it is too large
Load diff
|
@ -2,7 +2,8 @@
|
||||||
description = "cy's flake";
|
description = "cy's flake";
|
||||||
|
|
||||||
inputs = {
|
inputs = {
|
||||||
nixpkgs.url = "github:nixos/nixpkgs/nixos-unstable";
|
nixpkgs.url = "github:nixos/nixpkgs/nixos-unstable-small";
|
||||||
|
nixpkgs-stable.url = "github:nixos/nixpkgs/nixos-24.11";
|
||||||
sops-nix.url = "github:Mic92/sops-nix";
|
sops-nix.url = "github:Mic92/sops-nix";
|
||||||
sops-nix.inputs.nixpkgs.follows = "nixpkgs";
|
sops-nix.inputs.nixpkgs.follows = "nixpkgs";
|
||||||
home-manager.url = "github:nix-community/home-manager";
|
home-manager.url = "github:nix-community/home-manager";
|
||||||
|
@ -11,6 +12,9 @@
|
||||||
lanzaboote.inputs.nixpkgs.follows = "nixpkgs";
|
lanzaboote.inputs.nixpkgs.follows = "nixpkgs";
|
||||||
rust-overlay.url = "github:oxalica/rust-overlay";
|
rust-overlay.url = "github:oxalica/rust-overlay";
|
||||||
rust-overlay.inputs.nixpkgs.follows = "nixpkgs";
|
rust-overlay.inputs.nixpkgs.follows = "nixpkgs";
|
||||||
|
conduwuit.url = "github:girlbossceo/conduwuit";
|
||||||
|
conduwuit.inputs.nixpkgs.follows = "nixpkgs";
|
||||||
|
lix-module.url = "git+https://git.lix.systems/lix-project/nixos-module?ref=release-2.92";
|
||||||
nix-ld.url = "github:nix-community/nix-ld";
|
nix-ld.url = "github:nix-community/nix-ld";
|
||||||
nix-ld.inputs.nixpkgs.follows = "nixpkgs";
|
nix-ld.inputs.nixpkgs.follows = "nixpkgs";
|
||||||
nil.url = "github:oxalica/nil";
|
nil.url = "github:oxalica/nil";
|
||||||
|
@ -67,6 +71,7 @@
|
||||||
./modules
|
./modules
|
||||||
inputs.sops-nix.nixosModules.sops
|
inputs.sops-nix.nixosModules.sops
|
||||||
inputs.lanzaboote.nixosModules.lanzaboote
|
inputs.lanzaboote.nixosModules.lanzaboote
|
||||||
|
inputs.lix-module.nixosModules.default
|
||||||
inputs.nix-ld.nixosModules.nix-ld
|
inputs.nix-ld.nixosModules.nix-ld
|
||||||
];
|
];
|
||||||
};
|
};
|
||||||
|
@ -79,6 +84,7 @@
|
||||||
./hosts/chunk
|
./hosts/chunk
|
||||||
./modules
|
./modules
|
||||||
inputs.sops-nix.nixosModules.sops
|
inputs.sops-nix.nixosModules.sops
|
||||||
|
inputs.lix-module.nixosModules.default
|
||||||
];
|
];
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
6
garnix.yaml
Normal file
6
garnix.yaml
Normal file
|
@ -0,0 +1,6 @@
|
||||||
|
builds:
|
||||||
|
include:
|
||||||
|
- 'nixosConfigurations.*'
|
||||||
|
- 'homeConfigurations.*'
|
||||||
|
- '*.aarch64-linux.*'
|
||||||
|
- '*.x86_64-linux.*'
|
|
@ -73,7 +73,6 @@
|
||||||
"telemetry.enableTelemetry" = false;
|
"telemetry.enableTelemetry" = false;
|
||||||
"telemetry.telemetryLevel" = "off";
|
"telemetry.telemetryLevel" = "off";
|
||||||
"window.titleBarStyle" = "custom";
|
"window.titleBarStyle" = "custom";
|
||||||
"editor.formatOnSave" = true;
|
|
||||||
|
|
||||||
# terminal stuff
|
# terminal stuff
|
||||||
"terminal.integrated.cursorBlinking" = true;
|
"terminal.integrated.cursorBlinking" = true;
|
||||||
|
|
|
@ -7,6 +7,7 @@
|
||||||
package = pkgs.ibm-plex;
|
package = pkgs.ibm-plex;
|
||||||
size = 12;
|
size = 12;
|
||||||
};
|
};
|
||||||
|
themeFile = "GitHub_Dark";
|
||||||
settings = {
|
settings = {
|
||||||
enable_audio_bell = true;
|
enable_audio_bell = true;
|
||||||
# how many windows should be open before kitty asks
|
# how many windows should be open before kitty asks
|
||||||
|
|
|
@ -103,8 +103,6 @@
|
||||||
gopls
|
gopls
|
||||||
rust-analyzer
|
rust-analyzer
|
||||||
minio-client
|
minio-client
|
||||||
nil
|
|
||||||
keepassxc
|
|
||||||
];
|
];
|
||||||
|
|
||||||
home.sessionVariables = {
|
home.sessionVariables = {
|
||||||
|
@ -162,6 +160,4 @@
|
||||||
enable = true;
|
enable = true;
|
||||||
addKeysToAgent = "yes";
|
addKeysToAgent = "yes";
|
||||||
};
|
};
|
||||||
|
|
||||||
programs.firefox.enable = true;
|
|
||||||
}
|
}
|
||||||
|
|
33
hosts/chunk/conduwuit.nix
Normal file
33
hosts/chunk/conduwuit.nix
Normal file
|
@ -0,0 +1,33 @@
|
||||||
|
{ ... }:
|
||||||
|
{
|
||||||
|
services.conduwuit = {
|
||||||
|
enable = true;
|
||||||
|
settings.global = {
|
||||||
|
port = [ 8448 ];
|
||||||
|
server_name = "cything.io";
|
||||||
|
allow_check_for_updates = true;
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
|
services.caddy.virtualHosts."chat.cything.io".extraConfig = ''
|
||||||
|
import common
|
||||||
|
reverse_proxy localhost:8448
|
||||||
|
'';
|
||||||
|
|
||||||
|
services.caddy.virtualHosts."cything.io" = {
|
||||||
|
serverAliases = [ "www.cything.io" ];
|
||||||
|
extraConfig = ''
|
||||||
|
import common
|
||||||
|
|
||||||
|
header /.well-known/matrix/* Content-Type application/json
|
||||||
|
header /.well-known/matrix/* Access-Control-Allow-Origin *
|
||||||
|
header /.well-known/matrix/* Access-Control-Allow-Methods GET,POST,PUT,DELETE,OPTIONS,PATCH,HEAD
|
||||||
|
header /.well-known/matrix/* Access-Control-Allow-Headers X-Requested-With,Content-Type,Authorization,Origin,Accept
|
||||||
|
route {
|
||||||
|
respond /.well-known/matrix/server {"m.server":"chat.cything.io:443"}
|
||||||
|
respond /.well-known/matrix/client {"m.server":{"base_url":"https://chat.cything.io"},"m.homeserver":{"base_url":"https://chat.cything.io"},"org.matrix.msc3575.proxy":{"url":"https://chat.cything.io"}}
|
||||||
|
redir https://cy7.sh/posts{uri} permanent
|
||||||
|
}
|
||||||
|
'';
|
||||||
|
};
|
||||||
|
}
|
|
@ -16,6 +16,7 @@
|
||||||
./redlib.nix
|
./redlib.nix
|
||||||
./vaultwarden.nix
|
./vaultwarden.nix
|
||||||
./grafana.nix
|
./grafana.nix
|
||||||
|
./conduwuit.nix
|
||||||
./immich.nix
|
./immich.nix
|
||||||
./forgejo.nix
|
./forgejo.nix
|
||||||
./garage.nix
|
./garage.nix
|
||||||
|
@ -184,7 +185,7 @@
|
||||||
my.containerization.enable = true;
|
my.containerization.enable = true;
|
||||||
my.authelia.enable = true;
|
my.authelia.enable = true;
|
||||||
my.karakeep = {
|
my.karakeep = {
|
||||||
enable = false;
|
enable = true;
|
||||||
dataDir = "/opt/karakeep";
|
dataDir = "/opt/karakeep";
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,7 +1,6 @@
|
||||||
{ inputs, config, pkgs, ... }:
|
{ inputs, config, ... }:
|
||||||
{
|
{
|
||||||
nix = {
|
nix = {
|
||||||
package = pkgs.lix;
|
|
||||||
settings = {
|
settings = {
|
||||||
experimental-features = "nix-command flakes";
|
experimental-features = "nix-command flakes";
|
||||||
auto-optimise-store = true;
|
auto-optimise-store = true;
|
||||||
|
|
|
@ -21,7 +21,7 @@ in
|
||||||
# (still need the @ to pass nix config check)
|
# (still need the @ to pass nix config check)
|
||||||
"github.com/caddy-dns/cloudflare@v0.0.0-20250228175314-1fb64108d4de"
|
"github.com/caddy-dns/cloudflare@v0.0.0-20250228175314-1fb64108d4de"
|
||||||
];
|
];
|
||||||
hash = "sha256-pfh9DXUj35jlAntkWc4D5wuW04xxQfM1rZ4KFauMzvc=";
|
hash = "sha256-YYpsf8HMONR1teMiSymo2y+HrKoxuJMKIea5/NEykGc=";
|
||||||
};
|
};
|
||||||
logFormat = lib.mkForce "level INFO";
|
logFormat = lib.mkForce "level INFO";
|
||||||
acmeCA = "https://acme-v02.api.letsencrypt.org/directory";
|
acmeCA = "https://acme-v02.api.letsencrypt.org/directory";
|
||||||
|
|
|
@ -7,12 +7,14 @@
|
||||||
pkgFrom = flake: pkg: flake.packages.${prev.system}.${pkg};
|
pkgFrom = flake: pkg: flake.packages.${prev.system}.${pkg};
|
||||||
in
|
in
|
||||||
{
|
{
|
||||||
|
conduwuit = pkgFrom inputs.conduwuit "default";
|
||||||
|
attic-server = pkgFrom inputs.attic "attic-server";
|
||||||
|
attic = pkgFrom inputs.attic "attic";
|
||||||
garage = (
|
garage = (
|
||||||
(pkgFrom inputs.garage "default").overrideAttrs {
|
(pkgFrom inputs.garage "default").overrideAttrs {
|
||||||
meta.mainProgram = "garage";
|
meta.mainProgram = "garage";
|
||||||
}
|
}
|
||||||
);
|
);
|
||||||
nil = pkgFrom inputs.nil "default";
|
|
||||||
}
|
}
|
||||||
)
|
)
|
||||||
]
|
]
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue