add hydra declarative projects
This commit is contained in:
parent
6f0331a79e
commit
0c8eb5ed6a
4 changed files with 38 additions and 0 deletions
BIN
secrets/hydra-password
Normal file
BIN
secrets/hydra-password
Normal file
Binary file not shown.
|
@ -16,6 +16,7 @@ mkShell {
|
|||
p.cloudflare
|
||||
p.null
|
||||
p.external
|
||||
p.hydra
|
||||
]
|
||||
))
|
||||
sops
|
||||
|
@ -31,5 +32,6 @@ mkShell {
|
|||
|
||||
shellHook = ''
|
||||
export CLOUDFLARE_API_TOKEN=$(< ./secrets/cloudflare-api-token)
|
||||
export HYDRA_PASSWORD=$(< ./secrets/hydra-password)
|
||||
'';
|
||||
}
|
||||
|
|
28
terraform/hydra-jobsets.tf
Normal file
28
terraform/hydra-jobsets.tf
Normal file
|
@ -0,0 +1,28 @@
|
|||
resource "hydra_project" "kittybox" {
|
||||
name = "kittybox"
|
||||
display_name = "Kittybox"
|
||||
description = "The IndieWeb blogging solution"
|
||||
homepage = "https://gitlab.com/kittybox/kittybox"
|
||||
owner = "admin"
|
||||
enabled = true
|
||||
visible = true
|
||||
}
|
||||
|
||||
|
||||
resource "hydra_jobset" "kittybox" {
|
||||
project = hydra_project.kittybox.name
|
||||
state = "enabled"
|
||||
visible = true
|
||||
name = "main"
|
||||
type = "flake"
|
||||
description = "main branch"
|
||||
|
||||
flake_uri = "gitlab:kittybox/kittybox"
|
||||
|
||||
check_interval = 300
|
||||
scheduling_shares = 3000
|
||||
keep_evaluations = 3
|
||||
|
||||
email_notifications = false
|
||||
#email_override = ""
|
||||
}
|
|
@ -8,9 +8,17 @@ terraform {
|
|||
cloudflare = {
|
||||
source = "cloudflare/cloudflare"
|
||||
}
|
||||
hydra = {
|
||||
source = "DeterminateSystems/hydra"
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
provider "cloudflare" {
|
||||
account_id = "e4a2db52c495db230973c839a0699ae1"
|
||||
}
|
||||
|
||||
provider "hydra" {
|
||||
host = "https://hydra.nix-community.org"
|
||||
username = "admin"
|
||||
}
|
||||
|
|
Loading…
Add table
Reference in a new issue