Compare commits

...

2 commits

Author SHA1 Message Date
517774270e feat(systems): inject systemd-openbao project
This brings the openbao agent, a Go proxy to make the link between
systemd's LoadCredential and the openbao agent.

All that remains is to configure authentication on every system we need
to use OpenBao and then the templates for every secret we care about.

Signed-off-by: Raito Bezarius <masterancpp@gmail.com>
2025-01-01 02:20:36 +01:00
3b9f1e24a6 feat(systems): trust our infra chain on all systems
We remove one CA to send to all systems (infra CA).

Signed-off-by: Raito Bezarius <masterancpp@gmail.com>
2025-01-01 02:09:49 +01:00
5 changed files with 97 additions and 3 deletions

View file

@ -1,6 +1,6 @@
{
# Trust our ICA2 CA chain certificate.
# Trust our infrastructure CA chain certificate.
security.pki.certificateFiles = [
../pki/ica2.crt
../pki/infra.crt
];
}

View file

@ -789,6 +789,7 @@
"nixpkgs": "nixpkgs_2",
"ofborg": "ofborg",
"stateless-uptime-kuma": "stateless-uptime-kuma",
"systemd-openbao": "systemd-openbao",
"terranix": "terranix"
}
},
@ -853,6 +854,22 @@
"url": "https://git.dgnum.eu/DGNum/stateless-uptime-kuma.git"
}
},
"systemd-openbao": {
"flake": false,
"locked": {
"lastModified": 1735694158,
"narHash": "sha256-n8cyDX5qitjTNFQ2+nUeOpqSkXREir9p2bSqOZZ5sLs=",
"ref": "refs/heads/main",
"rev": "2479c46b0fa892c4fdcd3e315f0cdfe096b5e71a",
"revCount": 160,
"type": "git",
"url": "https://git.lix.systems/the-distro/systemd-openbao.git"
},
"original": {
"type": "git",
"url": "https://git.lix.systems/the-distro/systemd-openbao.git"
}
},
"systems": {
"locked": {
"lastModified": 1681028828,

View file

@ -41,6 +41,9 @@
channel-scripts.inputs.nixpkgs.follows = "nixpkgs";
channel-scripts.inputs.crane.inputs.attic.inputs.flake-compat.follows = "flake-compat";
systemd-openbao.url = "git+https://git.lix.systems/the-distro/systemd-openbao.git";
systemd-openbao.flake = false;
stateless-uptime-kuma.url = "git+https://git.dgnum.eu/DGNum/stateless-uptime-kuma.git";
stateless-uptime-kuma.flake = false;
@ -143,9 +146,13 @@
terraformConfiguration = forEachSystem' ({ terraformCfg, ... }: terraformCfg);
colmena = let
systemd-openbao = import inputs.systemd-openbao { };
commonModules = [
inputs.agenix.nixosModules.default
inputs.hydra.nixosModules.hydra
systemd-openbao.nixosModules.openbaoAgent
systemd-openbao.nixosModules.systemdOpenBaod
systemd-openbao.nixosModules.openbaoSecrets
inputs.buildbot-nix.nixosModules.buildbot-coordinator
inputs.buildbot-nix.nixosModules.buildbot-worker

View file

@ -10,4 +10,8 @@ The chain from ICA1 to root CA.
## `ica2.crt`
The chain from ICA2 to root CA (ICA2 → ICA → root CA), this is what you want to usually use to trust our PKI.
The chain from ICA2 to root CA (ICA2 → ICA1 → root CA), this is what you want to usually use to trust our PKI, assuming you send any intermediate CAs.
## `infra.crt`
The chain from the infra CA to root CA (infra → ICA2 → ICA1 → root CA), this is what you want to trust for the infrastructure.

66
pki/cacerts/infra.crt Normal file
View file

@ -0,0 +1,66 @@
-----BEGIN CERTIFICATE-----
MIICbDCCAh6gAwIBAgIUfzoqAP1fiwDncDYJjtLvHQcjobQwBQYDK2VwMIGaMQsw
CQYDVQQGEwJERTEPMA0GA1UECBMGSGVzc2VuMRIwEAYDVQQHEwlEYXJtc3RhZHQx
FzAVBgNVBAoTDkZsb3JhbCBTeXN0ZW1zMS0wKwYDVQQLEyRGbG9yYWwgU3lzdGVt
cyBDZXJ0aWZpY2F0ZSBBdXRob3JpdHkxHjAcBgNVBAMTFUludGVybWVkaWF0ZSBD
QTIgdjEuMTAeFw0yNTAxMDEwMTA3NDVaFw0yNjAxMDEwMTA4MTVaMIGoMQswCQYD
VQQGEwJERTEPMA0GA1UECBMGSGVzc2VuMRIwEAYDVQQHEwlEYXJtc3RhZHQxFzAV
BgNVBAoTDkZsb3JhbCBTeXN0ZW1zMS0wKwYDVQQLEyRGbG9yYWwgU3lzdGVtcyBD
ZXJ0aWZpY2F0ZSBBdXRob3JpdHkxLDAqBgNVBAMTI0ludGVybWVkaWF0ZSBJbmZy
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