Compare commits
26 commits
2025-04-05
...
main
Author | SHA1 | Date | |
---|---|---|---|
a7de77a0fc | |||
1b298adbf6 | |||
1cf31a7ae0 | |||
f3f15724d2 | |||
4f1bd26064 | |||
e38ed0e6f1 | |||
5a053b2379 | |||
eb054c444a | |||
2591401aa3 | |||
c193ba2108 | |||
140f0f5dcf | |||
4188e4aa83 | |||
44a98fd703 | |||
f5af830c30 | |||
b3f1d10575 | |||
61a4f97684 | |||
71657e0ccb | |||
e2df47ab99 | |||
c806ffb3bb | |||
21399aaf47 | |||
40d0a1512d | |||
68d6fcc45e | |||
904cecde76 | |||
e678d56cad | |||
2001228889 | |||
cad11e55f1 |
17 changed files with 128 additions and 985 deletions
106
.github/workflows/build-machines-and-homes.yml
vendored
106
.github/workflows/build-machines-and-homes.yml
vendored
|
@ -8,6 +8,8 @@ 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:
|
||||||
|
@ -35,7 +37,26 @@ jobs:
|
||||||
build-mount-path: /nix
|
build-mount-path: /nix
|
||||||
|
|
||||||
- name: setup binary cache key
|
- name: setup binary cache key
|
||||||
run: echo "${{ secrets.NIX_CACHE_SECRET_KEY }}" >> /home/runner/cache-priv-key.pem
|
run: echo -n "${{ secrets.NIX_CACHE_SECRET_KEY }}" | xxd -p -r > ${{ runner.temp }}/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
|
||||||
|
@ -46,39 +67,15 @@ 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 = /home/runner/cache-priv-key.pem
|
secret-key-files = ${{ runner.temp }}/cache-priv-key.pem
|
||||||
extra-substituters = https://nixcache.cy7.sh https://cache.lix.systems
|
extra-substituters = https://nixcache.cy7.sh
|
||||||
extra-trusted-public-keys = nixcache.cy7.sh:DN3d1dt0wnXfTH03oVmTee4KgmdNdB0NY3SuzA8Fwx8= cache.lix.systems:aBnZUw8zA7H35Cz2RyKFVs3H4PlGTLawyY5KRbvJR8o=
|
extra-trusted-public-keys = nixcache.cy7.sh:DN3d1dt0wnXfTH03oVmTee4KgmdNdB0NY3SuzA8Fwx8=
|
||||||
|
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
|
||||||
|
@ -105,7 +102,26 @@ jobs:
|
||||||
build-mount-path: /nix
|
build-mount-path: /nix
|
||||||
|
|
||||||
- name: setup binary cache key
|
- name: setup binary cache key
|
||||||
run: echo "${{ secrets.NIX_CACHE_SECRET_KEY }}" >> /home/runner/cache-priv-key.pem
|
run: echo -n "${{ secrets.NIX_CACHE_SECRET_KEY }}" | xxd -p -r > ${{ runner.temp }}/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
|
||||||
|
@ -116,34 +132,12 @@ 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 = /home/runner/cache-priv-key.pem
|
secret-key-files = ${{ runner.temp }}/cache-priv-key.pem
|
||||||
extra-substituters = https://nixcache.cy7.sh https://cache.lix.systems
|
extra-substituters = https://nixcache.cy7.sh
|
||||||
extra-trusted-public-keys = nixcache.cy7.sh:DN3d1dt0wnXfTH03oVmTee4KgmdNdB0NY3SuzA8Fwx8= cache.lix.systems:aBnZUw8zA7H35Cz2RyKFVs3H4PlGTLawyY5KRbvJR8o=
|
extra-trusted-public-keys = nixcache.cy7.sh:DN3d1dt0wnXfTH03oVmTee4KgmdNdB0NY3SuzA8Fwx8=
|
||||||
|
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,6 +11,8 @@ 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:
|
||||||
|
@ -22,13 +24,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 "${{ secrets.NIX_CACHE_SECRET_KEY }}" >> /home/runner/cache-priv-key.pem
|
run: echo -n "${{ secrets.NIX_CACHE_SECRET_KEY }}" | xxd -p -r > ${{ runner.temp }}/cache-priv-key.pem
|
||||||
|
|
||||||
- name: Install Nix
|
- name: Install Nix
|
||||||
uses: cachix/install-nix-action@v30
|
uses: cachix/install-nix-action@v30
|
||||||
|
@ -39,21 +41,9 @@ 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 = /home/runner/cache-priv-key.pem
|
secret-key-files = ${{ runner.temp }}/cache-priv-key.pem
|
||||||
extra-substituters = https://nixcache.cy7.sh https://cache.lix.systems
|
extra-substituters = https://nixcache.cy7.sh
|
||||||
extra-trusted-public-keys = nixcache.cy7.sh:DN3d1dt0wnXfTH03oVmTee4KgmdNdB0NY3SuzA8Fwx8= cache.lix.systems:aBnZUw8zA7H35Cz2RyKFVs3H4PlGTLawyY5KRbvJR8o=
|
extra-trusted-public-keys = nixcache.cy7.sh:DN3d1dt0wnXfTH03oVmTee4KgmdNdB0NY3SuzA8Fwx8=
|
||||||
|
|
||||||
- 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 }}
|
||||||
|
|
||||||
|
@ -61,10 +51,11 @@ jobs:
|
||||||
# https://stackoverflow.com/a/58859404
|
# https://stackoverflow.com/a/58859404
|
||||||
if: '!cancelled()'
|
if: '!cancelled()'
|
||||||
run: |
|
run: |
|
||||||
nix run git+https://git.cy7.sh/cy/nixcp.git -- \
|
nix run github:cything/nixcp -- \
|
||||||
--to 's3://nixcache?endpoint=s3.cy7.sh&secret-key=/home/runner/cache-priv-key.pem&compression=zstd' \
|
push \
|
||||||
|
--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
Normal file
1
README
Normal file
|
@ -0,0 +1 @@
|
||||||
|
this is only open source for free ci
|
40
README.md
40
README.md
|
@ -1,40 +0,0 @@
|
||||||
# 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
|
|
8
ci/upload-to-cache.sh
Executable file
8
ci/upload-to-cache.sh
Executable file
|
@ -0,0 +1,8 @@
|
||||||
|
#!/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,8 +2,7 @@
|
||||||
description = "cy's flake";
|
description = "cy's flake";
|
||||||
|
|
||||||
inputs = {
|
inputs = {
|
||||||
nixpkgs.url = "github:nixos/nixpkgs/nixos-unstable-small";
|
nixpkgs.url = "github:nixos/nixpkgs/nixos-unstable";
|
||||||
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";
|
||||||
|
@ -12,9 +11,6 @@
|
||||||
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";
|
||||||
|
@ -71,7 +67,6 @@
|
||||||
./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
|
||||||
];
|
];
|
||||||
};
|
};
|
||||||
|
@ -84,7 +79,6 @@
|
||||||
./hosts/chunk
|
./hosts/chunk
|
||||||
./modules
|
./modules
|
||||||
inputs.sops-nix.nixosModules.sops
|
inputs.sops-nix.nixosModules.sops
|
||||||
inputs.lix-module.nixosModules.default
|
|
||||||
];
|
];
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
|
@ -1,6 +0,0 @@
|
||||||
builds:
|
|
||||||
include:
|
|
||||||
- 'nixosConfigurations.*'
|
|
||||||
- 'homeConfigurations.*'
|
|
||||||
- '*.aarch64-linux.*'
|
|
||||||
- '*.x86_64-linux.*'
|
|
|
@ -23,8 +23,6 @@
|
||||||
tamasfe.even-better-toml
|
tamasfe.even-better-toml
|
||||||
golang.go
|
golang.go
|
||||||
ms-python.python
|
ms-python.python
|
||||||
christian-kohler.path-intellisense
|
|
||||||
# firefox-devtools.vscode-firefox-debug
|
|
||||||
];
|
];
|
||||||
userSettings =
|
userSettings =
|
||||||
let
|
let
|
||||||
|
@ -75,11 +73,7 @@
|
||||||
"telemetry.enableTelemetry" = false;
|
"telemetry.enableTelemetry" = false;
|
||||||
"telemetry.telemetryLevel" = "off";
|
"telemetry.telemetryLevel" = "off";
|
||||||
"window.titleBarStyle" = "custom";
|
"window.titleBarStyle" = "custom";
|
||||||
# https://github.com/ChristianKohler/PathIntellisense#installation
|
"editor.formatOnSave" = true;
|
||||||
"typescript.suggest.paths" = false;
|
|
||||||
"javascript.suggest.paths" = false;
|
|
||||||
|
|
||||||
"path-intellisense.absolutePathToWorkspace" = true;
|
|
||||||
|
|
||||||
# terminal stuff
|
# terminal stuff
|
||||||
"terminal.integrated.cursorBlinking" = true;
|
"terminal.integrated.cursorBlinking" = true;
|
||||||
|
|
|
@ -7,7 +7,6 @@
|
||||||
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,6 +103,8 @@
|
||||||
gopls
|
gopls
|
||||||
rust-analyzer
|
rust-analyzer
|
||||||
minio-client
|
minio-client
|
||||||
|
nil
|
||||||
|
keepassxc
|
||||||
];
|
];
|
||||||
|
|
||||||
home.sessionVariables = {
|
home.sessionVariables = {
|
||||||
|
@ -160,4 +162,6 @@
|
||||||
enable = true;
|
enable = true;
|
||||||
addKeysToAgent = "yes";
|
addKeysToAgent = "yes";
|
||||||
};
|
};
|
||||||
|
|
||||||
|
programs.firefox.enable = true;
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,33 +0,0 @@
|
||||||
{ ... }:
|
|
||||||
{
|
|
||||||
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,7 +16,6 @@
|
||||||
./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
|
||||||
|
@ -138,13 +137,15 @@
|
||||||
"podman"
|
"podman"
|
||||||
];
|
];
|
||||||
openssh.authorizedKeys.keys = [
|
openssh.authorizedKeys.keys = [
|
||||||
"ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIPdhAQYy0+vS+QmyCd0MAbqbgzyMGcsuuFyf6kg2yKge yt@ytlinux"
|
"ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIPdhAQYy0+vS+QmyCd0MAbqbgzyMGcsuuFyf6kg2yKge"
|
||||||
"ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIOfubDWr0kRm2o4DqaK6l1s4NCdTkljXZWKWCiF5nX+6"
|
"ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIOfubDWr0kRm2o4DqaK6l1s4NCdTkljXZWKWCiF5nX+6"
|
||||||
|
"sk-ssh-ed25519@openssh.com AAAAGnNrLXNzaC1lZDI1NTE5QG9wZW5zc2guY29tAAAAIA/IX9OFEhHS9Dl8nrtHkL7j7hhy7in9OAY/hVuzEGL0AAAABHNzaDo="
|
||||||
];
|
];
|
||||||
};
|
};
|
||||||
users.users.root.openssh.authorizedKeys.keys = [
|
users.users.root.openssh.authorizedKeys.keys = [
|
||||||
"ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIPdhAQYy0+vS+QmyCd0MAbqbgzyMGcsuuFyf6kg2yKge yt@ytlinux"
|
"ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIPdhAQYy0+vS+QmyCd0MAbqbgzyMGcsuuFyf6kg2yKge yt@ytlinux"
|
||||||
"ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIOfubDWr0kRm2o4DqaK6l1s4NCdTkljXZWKWCiF5nX+6"
|
"ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIOfubDWr0kRm2o4DqaK6l1s4NCdTkljXZWKWCiF5nX+6"
|
||||||
|
"sk-ssh-ed25519@openssh.com AAAAGnNrLXNzaC1lZDI1NTE5QG9wZW5zc2guY29tAAAAIA/IX9OFEhHS9Dl8nrtHkL7j7hhy7in9OAY/hVuzEGL0AAAABHNzaDo="
|
||||||
];
|
];
|
||||||
# for forgejo
|
# for forgejo
|
||||||
users.users.git = {
|
users.users.git = {
|
||||||
|
@ -183,7 +184,7 @@
|
||||||
my.containerization.enable = true;
|
my.containerization.enable = true;
|
||||||
my.authelia.enable = true;
|
my.authelia.enable = true;
|
||||||
my.karakeep = {
|
my.karakeep = {
|
||||||
enable = true;
|
enable = false;
|
||||||
dataDir = "/opt/karakeep";
|
dataDir = "/opt/karakeep";
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,6 +1,7 @@
|
||||||
{ inputs, config, ... }:
|
{ inputs, config, pkgs, ... }:
|
||||||
{
|
{
|
||||||
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;
|
||||||
|
|
|
@ -274,7 +274,6 @@
|
||||||
enable = true;
|
enable = true;
|
||||||
# nix run github:thiagokokada/nix-alien#nix-alien-find-libs ./<binary>
|
# nix run github:thiagokokada/nix-alien#nix-alien-find-libs ./<binary>
|
||||||
libraries = with pkgs; [
|
libraries = with pkgs; [
|
||||||
# TODO: revisit what we actually need
|
|
||||||
mesa
|
mesa
|
||||||
extest
|
extest
|
||||||
stdenv.cc.cc
|
stdenv.cc.cc
|
||||||
|
@ -330,6 +329,7 @@
|
||||||
pcre2
|
pcre2
|
||||||
gsettings-desktop-schemas
|
gsettings-desktop-schemas
|
||||||
fzf
|
fzf
|
||||||
|
systemd
|
||||||
];
|
];
|
||||||
};
|
};
|
||||||
programs.evolution.enable = true;
|
programs.evolution.enable = 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-YYpsf8HMONR1teMiSymo2y+HrKoxuJMKIea5/NEykGc=";
|
hash = "sha256-pfh9DXUj35jlAntkWc4D5wuW04xxQfM1rZ4KFauMzvc=";
|
||||||
};
|
};
|
||||||
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";
|
||||||
|
@ -49,7 +49,8 @@ in
|
||||||
respond / 200 {
|
respond / 200 {
|
||||||
body "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIOfubDWr0kRm2o4DqaK6l1s4NCdTkljXZWKWCiF5nX+6
|
body "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIOfubDWr0kRm2o4DqaK6l1s4NCdTkljXZWKWCiF5nX+6
|
||||||
ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIPhUt9h5dCcrwOrZNKkStCX5OxumPzEwYXSU/0DgtWgP
|
ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIPhUt9h5dCcrwOrZNKkStCX5OxumPzEwYXSU/0DgtWgP
|
||||||
ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAINyn2+OoRN4nExti+vFQ1NHEZip0slAoCH9C5/FzvgZD"
|
ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAINyn2+OoRN4nExti+vFQ1NHEZip0slAoCH9C5/FzvgZD
|
||||||
|
sk-ssh-ed25519@openssh.com AAAAGnNrLXNzaC1lZDI1NTE5QG9wZW5zc2guY29tAAAAIA/IX9OFEhHS9Dl8nrtHkL7j7hhy7in9OAY/hVuzEGL0AAAABHNzaDo="
|
||||||
}
|
}
|
||||||
'';
|
'';
|
||||||
};
|
};
|
||||||
|
|
|
@ -7,14 +7,12 @@
|
||||||
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