Skip to content

Commit f121c9c

Browse files
authored
chore: drop sops+age (#1)
* doc: remove sops+age * chore: rm gitleaks sops config * chore: rm sops config * chore: rm example env * chore(nix): drop sops+age from devShell * chore(just): rm sops just recipes * doc(contributing): formatting * doc(just): confirmation for cleanup
1 parent ac03ed4 commit f121c9c

8 files changed

Lines changed: 6 additions & 151 deletions

File tree

README.md

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -86,11 +86,6 @@ models:
8686
gpu: "0.2" # fraction of a gpu to use
8787
```
8888
89-
### Secrets
90-
91-
You may supply your encrypted deployment's secrets in `values.<env>.yaml`.
92-
This is set up to encrypt values with sops+age; if you maintain those, see [CONTRIBUTING.md](CONTRIBUTING.md#secrets).
93-
9489
### Manual installation steps
9590
9691
Some steps need to be done manually the first time this is deployed, since the relevant configuration can't be set automatically.

docs/CONTRIBUTING.md

Lines changed: 2 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -23,31 +23,9 @@ Without nix, run it manually once (it is idempotent).
2323

2424
## Common tasks
2525

26-
Run `just` (or `just --list`) to see everything. Tooling recipes are in the ### Manual installation steps
27-
justfile (e.g. `just lint`), whereas specialized recipes (e.g. `just sops::edit <file>`) are in just modules under `tools/just`.
26+
Run `just` (or `just --list`) to see everything. Tooling recipes are in the justfile (e.g. `just lint`),
27+
whereas specialized recipes (e.g. `just helm::template`) are in just modules under `tools/just`.
2828

2929
## pre-commit
3030

3131
Pre-commit hooks are set up via `prek` and run some `just` recipes.
32-
33-
## Secrets
34-
35-
Shared-deployment values files (`values.*.yaml`) are encrypted with
36-
[sops](https://github.com/getsops/sops) and [age](https://github.com/FiloSottile/age);
37-
`tools/config/.sops.yaml` controls which keys can decrypt them and which fields are encrypted.
38-
39-
One-time setup:
40-
41-
1. Create an encrypted age key file: `just sops::keygen <key-path>.age`
42-
2. Ask someone already listed in `tools/config/.sops.yaml` to add your public key and
43-
re-encrypt (`just sops::updatekeys`).
44-
3. Tell `just`/sops where your key is: copy `example.env` to `.env` (gitignored,
45-
auto-loaded by `just`) and set `SOPS_AGE_KEY_FILE` to your key's path.
46-
47-
To work with encrypted files, list recipes by running `just sops`.
48-
49-
> [!NOTE]
50-
>
51-
> If you wish to run sops/age directly without using just,
52-
> make sure to export `SOPS_AGE_KEY_FILE` and point sops to
53-
> the config using `--config tools/config/..sops.yaml`.

example.env

Lines changed: 0 additions & 1 deletion
This file was deleted.

justfile

Lines changed: 4 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -10,9 +10,6 @@ go_modules := "scripts/init otlp-openmeter-bridge"
1010
# Manage nix environment.
1111
[group('modules')]
1212
mod nix "./tools/just/nix.just"
13-
# Manage secrets with sops+age.
14-
[group('modules')]
15-
mod sops "./tools/just/sops.just"
1613
# Manage the helm chart.
1714
[group('modules')]
1815
mod helm "./tools/just/helm.just"
@@ -60,8 +57,9 @@ build *args:
6057
6158
# Clean up generated files.
6259
[group('general')]
60+
[confirm("Delete everything in:\n" + output_dir + "?\n [y/n]")]
6361
clean: helm::clean
64-
rm -r "{{output_dir}}"/*
62+
rm -fr "{{output_dir}}"/*
6563

6664
# Test the Go modules.
6765
[group('general')]
@@ -74,9 +72,7 @@ test *args:
7472
# Deploy Helm chart.
7573
[group('chart')]
7674
deploy namespace release values_file:
77-
just sops::run exec-file \
78-
"{{values_file}}" \
79-
'helm upgrade --install -n "{{namespace}}" "{{release}}" . --values "{}"'
75+
helm upgrade --install -n "{{namespace}}" "{{release}}" . --values "{{values_file}}"
8076

8177
# Errors if the repository contains unformatted files.
8278
[private]
@@ -87,4 +83,4 @@ check-format *args:
8783
# Check for secret leaks.
8884
[private]
8985
check-leaks *args:
90-
gitleaks git --config ./tools/config/gitleaks_extend.toml {{args}}
86+
gitleaks git {{args}}

tools/config/gitleaks_extend.toml

Lines changed: 0 additions & 17 deletions
This file was deleted.

tools/config/sops.yaml

Lines changed: 0 additions & 17 deletions
This file was deleted.

tools/just/sops.just

Lines changed: 0 additions & 77 deletions
This file was deleted.

tools/nix/flake.nix

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -67,10 +67,8 @@
6767
(callPackage ./packages/helmfmt.nix { helmfmt-src = inputs.helmfmt-src; })
6868
];
6969
devTools = with pkgs; [
70-
age
7170
gitleaks
7271
prek
73-
sops
7472
zsh
7573
];
7674
goModule = import ./modules/go.nix { inherit pkgs; };

0 commit comments

Comments
 (0)