2022-03-14 23:34:33 +00:00
|
|
|
{ lib, config, ... }:
|
2022-03-14 21:29:15 +00:00
|
|
|
|
|
|
|
{
|
2022-03-14 23:34:33 +00:00
|
|
|
imports = [
|
|
|
|
./policies-raw.nix
|
|
|
|
./policies-app.nix
|
|
|
|
|
|
|
|
./authbackend-approle.nix
|
|
|
|
./authbackend-oidc.nix
|
|
|
|
|
|
|
|
./ssh-ca-client.nix
|
|
|
|
./ssh-ca-server.nix
|
|
|
|
|
|
|
|
./servers.nix
|
2022-03-16 00:18:47 +00:00
|
|
|
|
|
|
|
./acme-ca.nix
|
2022-03-14 23:34:33 +00:00
|
|
|
];
|
|
|
|
|
2022-03-14 21:29:15 +00:00
|
|
|
terraform = {
|
|
|
|
backend.gcs = {
|
|
|
|
bucket = "lukegb-terraform-state";
|
|
|
|
prefix = "depot/vault";
|
|
|
|
};
|
|
|
|
|
|
|
|
required_providers.vault = {
|
|
|
|
source = "hashicorp/vault";
|
|
|
|
version = "3.3.1";
|
|
|
|
};
|
|
|
|
};
|
2022-03-14 23:34:33 +00:00
|
|
|
|
|
|
|
provider.vault = {
|
|
|
|
address = "https://vault.int.lukegb.com";
|
|
|
|
};
|
|
|
|
|
2022-03-16 00:06:46 +00:00
|
|
|
data.vault_generic_secret.misc = {
|
|
|
|
path = "kv/misc-input";
|
|
|
|
};
|
|
|
|
|
2022-03-14 23:34:33 +00:00
|
|
|
my.apps.pomerium = {};
|
|
|
|
my.servers.etheroute-lon01.apps = [ "pomerium" ];
|
2022-03-20 17:47:52 +00:00
|
|
|
|
|
|
|
my.apps.sslrenew-raritan = {
|
|
|
|
policy = ''
|
|
|
|
# sslrenew-raritan is permitted to issue certificates.
|
|
|
|
path "acme/certs/*" {
|
|
|
|
capabilities = ["create"]
|
|
|
|
}
|
|
|
|
'';
|
|
|
|
};
|
|
|
|
my.servers.totoro.apps = [ "sslrenew-raritan" ];
|
2022-03-24 22:20:44 +00:00
|
|
|
|
|
|
|
my.apps.deployer.policy = ''
|
|
|
|
# Allow reading nix-daemon secrets
|
|
|
|
path "kv/data/apps/nix-daemon" {
|
|
|
|
capabilities = ["read"]
|
|
|
|
}
|
|
|
|
path "kv/metadata/apps/nix-daemon" {
|
|
|
|
capabilities = ["read"]
|
|
|
|
}
|
|
|
|
'';
|
2022-03-14 21:29:15 +00:00
|
|
|
}
|