From 43930cb8c22bc28ed64362845c5f4ebf54faabf2 Mon Sep 17 00:00:00 2001 From: Kumar Damani Date: Sat, 1 Aug 2026 21:43:25 -0400 Subject: added git with cgit --- nix/README.md | 70 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++--- 1 file changed, 67 insertions(+), 3 deletions(-) (limited to 'nix/README.md') diff --git a/nix/README.md b/nix/README.md index 08d7305..a85e478 100644 --- a/nix/README.md +++ b/nix/README.md @@ -1,3 +1,7 @@ +# Deploy + +## Setup (one time) + Build base image: ```sh nixos-rebuild build-image --image-variant proxmox --flake .#base @@ -14,17 +18,77 @@ Convert to Proxmox Template. Run TF as usual using clone against the Template. +Generate host-keys, and age key for the host. ```sh # first time only ./generate-keys.sh torrents--2 +``` + +## Secrets w/ `sops` -# edit the .sops.yaml to include the host's age key +Edit the `.sops.yaml` to include the host's age key + +Create host's secrets: +```sh +sops secrets/torrents-2.yaml +``` -sops secrets/rproxy-2.yaml +## Push +```sh ./deploy.sh torrents-2 root ``` -Sources: +## References: + https://github.com/nix-community/nixos-generators https://gist.github.com/joshleecreates/e6892ca21b0e6b7c24d96ca2a24bf23e + +# Hosts + +## torrents-2 + +For all my Linux ISOs ofcourse. + +## rproxy-2 + +Entrypoint into my home-lab services. + +## git + +Set your `sshconfig`: +```sshconfig +# ~/.ssh/config +Host git.kumardamani.net + Port 2222 +``` + +> Non-SSH access (https) is always read-only, and anonymous. + +Manage repos with: +```sh +ssh -t git@git.kumardamani.net + +== git repo manager == + l) list repos + c) create repo + p) publish repo + h) hide repo + d) set description + x) delete repo + q) quit +> +``` + +Without the ssh config entry, use the abs path: +```sh +git clone ssh://git@git.kumardamani.net:2222/srv/git/.git +``` + +Move an existing local repo onto the server: +```sh +ssh git@git.kumardamani.net create +ssh git@git.kumardamani.net publish +git remote set-url origin git@git.kumardamani.net: +git push --all origin && git push --tags origin +``` -- cgit v1.2.3