Skip to content

Commit

Permalink
Match service using network and version labels
Browse files Browse the repository at this point in the history
  • Loading branch information
gonzalezzfelipe committed Feb 7, 2024
1 parent dd5cf5e commit 440b1f9
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 3 deletions.
6 changes: 4 additions & 2 deletions bootstrap/instance/ogmios.tf
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ locals {

resource "kubernetes_deployment_v1" "ogmios" {
metadata {
name = local.name
name = local.name
namespace = var.namespace
labels = {
"demeter.run/kind" = "OgmiosInstance"
Expand All @@ -18,7 +18,9 @@ resource "kubernetes_deployment_v1" "ogmios" {
replicas = var.replicas
selector {
match_labels = {
"demeter.run/instance" = local.name
"demeter.run/instance" = local.name
"cardano.demeter.run/network" = var.network
"cardano.demeter.run/ogmios_version" = var.ogmios_version
}
}
template {
Expand Down
3 changes: 2 additions & 1 deletion bootstrap/service/service.tf
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,8 @@ resource "kubernetes_service_v1" "well_known_service" {

spec {
selector = {
"demeter.run/instance" = local.name
"cardano.demeter.run/network" = var.network
"cardano.demeter.run/ogmios_version" = var.ogmios_version
}

port {
Expand Down

0 comments on commit 440b1f9

Please sign in to comment.