core-services-01(services): add Drone Server CI/CD for initial experiments
This commit is contained in:
parent
1c77fddc2c
commit
11298e3363
7 changed files with 30 additions and 1 deletions
25
machines/core-services-01/drone.nix
Normal file
25
machines/core-services-01/drone.nix
Normal file
|
@ -0,0 +1,25 @@
|
|||
{ config, lib, ... }:
|
||||
let
|
||||
port = 3030;
|
||||
in
|
||||
{
|
||||
nixpkgs.config.allowUnfreePredicate = pkg: builtins.elem (lib.getName pkg) [
|
||||
"drone.io"
|
||||
];
|
||||
services.drone-server = {
|
||||
enable = true;
|
||||
env = [
|
||||
"DRONE_USER_CREATE=username:rz,admin:true"
|
||||
];
|
||||
envFile = config.age.secrets.droneKeyFile.path;
|
||||
inherit port;
|
||||
};
|
||||
|
||||
services.nginx.virtualHosts."drone.rz.ens.wtf" = {
|
||||
enableACME = true;
|
||||
forceSSL = true;
|
||||
locations."/" = {
|
||||
proxyPass = "http://127.0.0.1:${toString port}";
|
||||
};
|
||||
};
|
||||
}
|
|
@ -5,6 +5,7 @@ let
|
|||
port = 3000;
|
||||
in
|
||||
{
|
||||
imports = [ ./drone.nix ];
|
||||
services.gitea = {
|
||||
enable = true;
|
||||
domain = "git.${my.subZone}";
|
||||
|
|
|
@ -14,7 +14,7 @@
|
|||
"klubrz-nur": {
|
||||
"branch": "main",
|
||||
"repo": "https://git.rz.ens.wtf/Klub-RZ/nur",
|
||||
"rev": "48597e362c87365976ebc0168fb0e5678aa3865d",
|
||||
"rev": "a567fa82ffcde61719c5409c472360eaee7b9611",
|
||||
"type": "git"
|
||||
},
|
||||
"niv": {
|
||||
|
|
|
@ -2,4 +2,5 @@
|
|||
{
|
||||
age.secrets.keycloakDatabasePasswordFile.file = ./keycloakDatabasePasswordFile.age;
|
||||
age.secrets.oauth2ProxyKeyFile.file = ./oauth2ProxyKeyFile.age;
|
||||
age.secrets.droneKeyFile.file = ./droneKeyFile.age;
|
||||
}
|
||||
|
|
BIN
machines/core-services-01/secrets/droneKeyFile.age
Normal file
BIN
machines/core-services-01/secrets/droneKeyFile.age
Normal file
Binary file not shown.
|
@ -9,5 +9,6 @@ in
|
|||
{
|
||||
"keycloakDatabasePasswordFile.age".publicKeys = superadmins ++ systems;
|
||||
"oauth2ProxyKeyFile.age".publicKeys = superadmins ++ systems;
|
||||
"droneKeyFile.age".publicKeys = superadmins ++ systems;
|
||||
}
|
||||
|
||||
|
|
|
@ -24,6 +24,7 @@ with my.ipv6; # contains { standard, acme }
|
|||
|
||||
subdomains = {
|
||||
git.AAAA = standard;
|
||||
drone.AAAA = standard;
|
||||
wiki.AAAA = standard;
|
||||
monitoring.AAAA = standard;
|
||||
auth.AAAA = standard;
|
||||
|
|
Loading…
Reference in a new issue