Repository navigation
feat: stash on hank, a new app vm - #80
Merged
Merged
Conversation
…ndition, exports and host lists
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Declares hank, a new lab VM for Stash (the Patchwork archive, patchworklabsorg/stash), and everything around it. The VM is not built yet.
stash-webandstash-workerfromghcr.io/patchworklabsorg/stash, host network, archived files on a host directory bind-mounted into both containers, worker with--shm-size 1g --memory 3g --memory-swap 3gmodules/stash/default.nix, exported asnixosModules.stashtailscale0:80, production on 3007 and staging on 3008, uid 1000 reserved for the containershosts/hank/,terraform/proxmox/variables.tfstashrole and schema inpatchwork_central(skein and hem)hosts/central-db-schema.nixstash.patchworklabs.organdstash-staging.patchworklabs.orghosts/alastor/edge.nixsecrets/,bin/new-stash-secretshankinlinuxHosts,hank-admins(Jasper)ad/org.jsonflowchart LR internet((Internet)) --> alastor["alastor (Traefik)"] alastor -- "tailnet, HTTP :80" --> hank["hank: nginx -> stash-web :3007 / :3008"] hank -- "tailnet :5432" --> skein["skein: patchwork_central, schema stash"] hank -. "staging :5432" .-> hem["hem: central staging"] worker["stash-worker: Chromium, git, yt-dlp, LibreOffice"] --> data[("/data/stash")] hank --- workerChecks:
nix flake check --no-buildpasses (the x86_64 VM tests did not build here).nix evalof the hank units gives the expecteddocker runcommands. The adversarial review's high finding (artifact downloads fail with the disk service) is fixed in Stash (ActiveStorage::SetCurrent, patchworklabsorg/stash6167a23); its medium and low findings are in the second commit.Decisions: the archived files live on hank's disk instead of an S3 bucket, so Stash does not depend on Krater's SeaweedFS on weft.
STASH_STORAGE_SERVICE=s3with theS3_*variables in the env file switches later. Nothing backs up/data/stashyet: that is owed before the first real capture.Steps after merge, in order:
bin/install-host hank, then put hank's host key insecrets/secrets.nix(the two env files andad-join.age) andagenix -r.stashrole gets its password.https://stash.patchworklabs.org/auth/callback, scopes openid profile email roles plus introspect, app roles viewer, archivist, admin) and fillWEAVE_CLIENT_IDandWEAVE_CLIENT_SECRETintostash-env.age; the same with Weave staging forstash-staging-env.age.deploy .#hank, thennix flake update patchwork-infraand deploy alastor for the routes.