From 9c55432be1929232fea3779bee03354b1285ea83 Mon Sep 17 00:00:00 2001 From: Noratrieb <48135649+Noratrieb@users.noreply.github.com> Date: Sun, 28 Jul 2024 12:28:15 +0200 Subject: [PATCH] add minio --- .gitattributes | 1 + newinfra/nix/hive.nix | 1 + newinfra/nix/modules/minio/default.nix | 9 +++++++++ newinfra/nix/secrets/minio_env_file.age | 6 ++++++ newinfra/nix/secrets/secrets.nix | 1 + newinfra/secrets-git-crypt/minio_env_file | Bin 0 -> 97 bytes .../secrets-git-crypt/widetom_bot_token | Bin .../secrets-git-crypt/widetom_config.toml | Bin 8 files changed, 18 insertions(+) create mode 100644 newinfra/nix/modules/minio/default.nix create mode 100644 newinfra/nix/secrets/minio_env_file.age create mode 100644 newinfra/secrets-git-crypt/minio_env_file rename secrets/widetom/bot_token => newinfra/secrets-git-crypt/widetom_bot_token (100%) rename secrets/widetom/config.toml => newinfra/secrets-git-crypt/widetom_config.toml (100%) diff --git a/.gitattributes b/.gitattributes index 2775dbc..d688e0f 100644 --- a/.gitattributes +++ b/.gitattributes @@ -2,3 +2,4 @@ *.yml linguist-detectable /secrets/** filter=git-crypt diff=git-crypt +/newinfra/secrets-git-crypt/** filter=git-crypt diff=git-crypt diff --git a/newinfra/nix/hive.nix b/newinfra/nix/hive.nix index 76bf67f..d8aac22 100644 --- a/newinfra/nix/hive.nix +++ b/newinfra/nix/hive.nix @@ -117,6 +117,7 @@ (modulesPath + "/profiles/qemu-guest.nix") ./modules/contabo ./modules/ingress + ./modules/minio ./modules/widetom ]; diff --git a/newinfra/nix/modules/minio/default.nix b/newinfra/nix/modules/minio/default.nix new file mode 100644 index 0000000..30420a1 --- /dev/null +++ b/newinfra/nix/modules/minio/default.nix @@ -0,0 +1,9 @@ +{ config, ... }: { + age.secrets.minio_env_file.file = ../../secrets/minio_env_file.age; + + services.minio = { + enable = true; + region = "eu"; + rootCredentialsFile = config.age.secrets.minio_env_file.path; + }; +} diff --git a/newinfra/nix/secrets/minio_env_file.age b/newinfra/nix/secrets/minio_env_file.age new file mode 100644 index 0000000..5f3f794 --- /dev/null +++ b/newinfra/nix/secrets/minio_env_file.age @@ -0,0 +1,6 @@ +age-encryption.org/v1 +-> ssh-ed25519 cVCt6g aURyPoqVOIH8dVpkyn+mb8rxwv1hw2hazAgLj/qDxzM +bOkR3mOiK9pA8CQxTGLpd52UyrTWvZ4cPz4m/khin5w +--- ALJ+6QKzH/CrCZ8FzdeWFRFZKFt6YOF0bKpLri7yCpU +NBaJya 8[Շ鶼Cɳ7XMBC!c pm_wDzoยH'i +i8ɛ:t/=`OkZұ \ No newline at end of file diff --git a/newinfra/nix/secrets/secrets.nix b/newinfra/nix/secrets/secrets.nix index 8501dac..239962f 100644 --- a/newinfra/nix/secrets/secrets.nix +++ b/newinfra/nix/secrets/secrets.nix @@ -5,4 +5,5 @@ in "widetom_bot_token.age".publicKeys = [ vps1 ]; "widetom_config_toml.age".publicKeys = [ vps1 ]; "docker_registry_password.age".publicKeys = [ vps1 ]; + "minio_env_file.age".publicKeys = [ vps1 ]; } diff --git a/newinfra/secrets-git-crypt/minio_env_file b/newinfra/secrets-git-crypt/minio_env_file new file mode 100644 index 0000000000000000000000000000000000000000..40fc20d7701a44253b760e1935a221a82bce72cf GIT binary patch literal 97 zcmZQ@_Y83kiVO&0kV=0pAQ_ya@+Y4=@tg8i&y~u;UM#V@gQxyH-P8I^*k;%5fE6(@ zR;F2h9!@$bubs4M`xRGV!Nqg;Z9OIy(p<{KFQYy$#Q5oy-%9+`gB>Ow;I7{HHK?u) E0Dwv