Skip to content

Commit

Permalink
fix: Admin key is now a secret and protocol parameters is added
Browse files Browse the repository at this point in the history
  • Loading branch information
gonzalezzfelipe committed Nov 4, 2024
1 parent c4d9d80 commit aa3fdda
Show file tree
Hide file tree
Showing 10 changed files with 721 additions and 27 deletions.
2 changes: 1 addition & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ result*
.envrc
.direnv
# runtime
protocol-parameters.json
# protocol-parameters.json
utxo.json
*.vk
*.sk
Expand Down
4 changes: 2 additions & 2 deletions bootstrap/stage0/cluster.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,15 +10,15 @@ metadata:

managedNodeGroups:
# Consistent
- name: be-ad-x86-az1
- name: be-adm-x86-az1
tags:
sundae-labs:cost-allocation:Service: hydra-doom
labels:
hydra.doom/availability-sla: best-effort
hydra.doom/compute-profile: admin
hydra.doom/compute-arch: x86
hydra.doom/availability-zone: az1
instanceType: t3a.medium
instanceTypes: [ t3a.medium, t3.medium ]
minSize: 0
maxSize: 2
desiredCapacity: 1
Expand Down
36 changes: 18 additions & 18 deletions bootstrap/stage1/crd.tf
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
resource "kubernetes_manifest" "customresourcedefinition_hydradoomnodes_hydra_doom" {
manifest = {
"apiVersion" = "apiextensions.k8s.io/v1"
"kind" = "CustomResourceDefinition"
"kind" = "CustomResourceDefinition"
"metadata" = {
"name" = "hydradoomnodes.hydra.doom"
}
Expand All @@ -11,7 +11,7 @@ resource "kubernetes_manifest" "customresourcedefinition_hydradoomnodes_hydra_do
"categories" = [
"hydradoom",
]
"kind" = "HydraDoomNode"
"kind" = "HydraDoomNode"
"plural" = "hydradoomnodes"
"shortNames" = [
"hydradoomnode",
Expand All @@ -24,23 +24,23 @@ resource "kubernetes_manifest" "customresourcedefinition_hydradoomnodes_hydra_do
"additionalPrinterColumns" = [
{
"jsonPath" = ".status.state"
"name" = "State"
"type" = "string"
"name" = "State"
"type" = "string"
},
{
"jsonPath" = ".status.transactions"
"name" = "Transactions"
"type" = "string"
"name" = "Transactions"
"type" = "string"
},
{
"jsonPath" = ".status.localUrl"
"name" = "Local URI"
"type" = "string"
"name" = "Local URI"
"type" = "string"
},
{
"jsonPath" = ".status.externalUrl"
"name" = "External URI"
"type" = "string"
"name" = "External URI"
"type" = "string"
},
]
"name" = "v1alpha1"
Expand All @@ -52,7 +52,7 @@ resource "kubernetes_manifest" "customresourcedefinition_hydradoomnodes_hydra_do
"properties" = {
"blockfrostKey" = {
"nullable" = true
"type" = "string"
"type" = "string"
}
"commitInputs" = {
"items" = {
Expand All @@ -62,16 +62,16 @@ resource "kubernetes_manifest" "customresourcedefinition_hydradoomnodes_hydra_do
}
"initialUtxoAddress" = {
"nullable" = true
"type" = "string"
"type" = "string"
}
"networkId" = {
"format" = "uint8"
"format" = "uint8"
"minimum" = 0
"type" = "integer"
"type" = "integer"
}
"offline" = {
"nullable" = true
"type" = "boolean"
"type" = "boolean"
}
"participant" = {
"type" = "string"
Expand Down Expand Up @@ -106,7 +106,7 @@ resource "kubernetes_manifest" "customresourcedefinition_hydradoomnodes_hydra_do
}
"transactions" = {
"format" = "int64"
"type" = "integer"
"type" = "integer"
}
}
"required" = [
Expand All @@ -122,10 +122,10 @@ resource "kubernetes_manifest" "customresourcedefinition_hydradoomnodes_hydra_do
"spec",
]
"title" = "HydraDoomNode"
"type" = "object"
"type" = "object"
}
}
"served" = true
"served" = true
"storage" = true
"subresources" = {
"status" = {}
Expand Down
5 changes: 5 additions & 0 deletions bootstrap/stage2/deployment.tf
Original file line number Diff line number Diff line change
Expand Up @@ -60,6 +60,11 @@ resource "kubernetes_deployment_v1" "operator" {
value = local.configmap
}

env {
name = "SECRET"
value = local.secret
}

env {
name = "BLOCKFROST_KEY"
value = var.blockfrost_key
Expand Down
1 change: 1 addition & 0 deletions bootstrap/stage2/main.tf
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
locals {
operator_component = "operator"
configmap = "hydra-pod-config"
secret = "hydra-pod-admin-key"
control_plane_component = "control-plane"
}

Expand Down
Loading

0 comments on commit aa3fdda

Please sign in to comment.