Use git-crypt for Soundcloud API key

This commit is contained in:
coolneng 2021-08-09 23:15:57 +01:00
parent 0aa1724bba
commit 38a2fd5eab
Signed by: coolneng
GPG Key ID: 9893DA236405AF57
7 changed files with 8 additions and 17 deletions

1
.gitattributes vendored Normal file
View File

@ -0,0 +1 @@
secrets/soundcloud_token filter=git-crypt diff=git-crypt

View File

@ -98,10 +98,7 @@
};
# Specify secrets
age.secrets = {
soundcloud_api_key.file = secrets/soundcloud_api_key.age;
wireguard.file = secrets/wireguard.age;
};
age.secrets.wireguard.file = secrets/wireguard.age;
# Import other configuration modules
imports = [

View File

@ -1,6 +1,8 @@
{ config, lib, pkgs, ... }:
{
let soundcloud_token = builtins.readFile ../secrets/soundcloud_token;
in {
# Configure pipewire as sound server
services.pipewire = {
enable = true;
@ -64,7 +66,7 @@
[soundcloud]
enabled = true
auth_token = ${config.age.secrets.soundcloud_api_key.path}
auth_token = ${soundcloud_token}
explore_songs = 100
[m3u]

View File

@ -17,6 +17,7 @@ in {
passff-host
gitAndTools.pass-git-helper
inputs.agenix.defaultPackage.x86_64-linux
git-crypt
# Browsers
firefox
ungoogled-chromium

View File

@ -1,7 +1,4 @@
let
coolneng =
"ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIC57m1j/G6iQyi2EpU3nj3+df5Z4PL/XbiOmDcqA7ODg";
in {
"soundcloud_api_key.age".publicKeys = [ coolneng ];
"wireguard.age".publicKeys = [ coolneng ];
}
in { "wireguard.age".publicKeys = [ coolneng ]; }

View File

@ -1,7 +0,0 @@
age-encryption.org/v1
-> ssh-ed25519 G5UUhw tVGNxVkibTRSr8c2l7Wmo3pMhnyI6JHBZzddC93sv2E
0NOlI4vaBZz+Wg7LDji6CRrNsBPVhQ5rFyjPUe+ekg0
-> *NFvF-grease b1zp>
TIRHkh0
--- Y9Rt0ibteW6VSuzIGt4EenoFoOmRnvIUeFbJkqkL5m4
P隝}ォョ7ゥ}t逋vヒ酢T[c#ibカC<EFBDB6>i|カホオ?%%リシ」lッニDアワノアュ羊・Iェy,Z{」、 _

BIN
secrets/soundcloud_token Normal file

Binary file not shown.