forked from Fediversity/Fediversity
Make forgejo-ci
a Frogejo actions runner
This commit is contained in:
parent
09ea1acdbe
commit
af66aef50d
3 changed files with 49 additions and 1 deletions
|
@ -8,6 +8,7 @@ in
|
|||
imports = [
|
||||
../common/options.nix
|
||||
../common/nixos
|
||||
./forgejo-actions-runner.nix
|
||||
];
|
||||
|
||||
procolixVm = {
|
||||
|
|
44
infra/forgejo-ci/forgejo-actions-runner.nix
Normal file
44
infra/forgejo-ci/forgejo-actions-runner.nix
Normal file
|
@ -0,0 +1,44 @@
|
|||
{ pkgs, config, ... }:
|
||||
|
||||
{
|
||||
services.gitea-actions-runner = {
|
||||
package = pkgs.forgejo-actions-runner;
|
||||
|
||||
instances.default = {
|
||||
enable = true;
|
||||
|
||||
name = config.networking.fqdn;
|
||||
url = "https://git.fediversity.eu";
|
||||
tokenFile = config.age.secrets.forgejo-runner-token.path;
|
||||
|
||||
settings = {
|
||||
log.level = "info";
|
||||
runner = {
|
||||
file = ".runner";
|
||||
capacity = 24;
|
||||
timeout = "3h";
|
||||
insecure = false;
|
||||
fetch_timeout = "5s";
|
||||
fetch_interval = "2s";
|
||||
};
|
||||
};
|
||||
|
||||
## This runner supports Docker (with a default Ubuntu image) and native
|
||||
## modes. In native mode, it contains a few default packages.
|
||||
labels = [
|
||||
"docker:docker://node:16-bullseye"
|
||||
"native:host"
|
||||
];
|
||||
|
||||
hostPackages = with pkgs; [
|
||||
bash
|
||||
git
|
||||
nix
|
||||
nodejs
|
||||
];
|
||||
};
|
||||
};
|
||||
|
||||
## For the Docker mode of the runner.
|
||||
virtualisation.docker.enable = true;
|
||||
}
|
|
@ -26,7 +26,10 @@ concatMapAttrs
|
|||
{
|
||||
forgejo-database-password = [ vm02116 ];
|
||||
forgejo-email-password = [ vm02116 ];
|
||||
forgejo-runner-token = [ ];
|
||||
forgejo-runner-token = [
|
||||
fedi300
|
||||
forgejo-ci
|
||||
];
|
||||
panel-secret-key = [ fedi201 ];
|
||||
panel-ssh-key = [ fedi201 ];
|
||||
wiki-basicauth-htpasswd = [ vm02187 ];
|
||||
|
|
Loading…
Add table
Reference in a new issue