Elffuss BraidHub

kikocis/EonaX-Shared-Resources public

main · 2.7 KiBRawPermalink
1locals {
2 controlplane_release_name = "controlplane"
3}
4
5resource "helm_release" "controlplane" {
6 name = local.controlplane_release_name
7 cleanup_on_fail = true
8 dependency_update = true
9 recreate_pods = true
10 chart = "./controlplane.tgz"
11
12 values = [
13 yamlencode({
14 "controlplane" : {
15 "image" : {
16 "repository" : "eonax-control-plane-postgresql-hashicorpvault"
17 "tag" : "latest"
18 "pullPolicy" : "Never"
19 },
20 "keys" : {
21 "sts" : {
22 "privateKeyVaultAlias" : var.private_key_alias,
23 "publicKeyId" : "${var.identity_hub_did_web_url}#my-key"
24 }
25 },
26 "did" : {
27 "web" : {
28 "url" : var.identity_hub_did_web_url
29 "useHttps" : false
30 }
31 },
32
33 "url" : {
34 "protocol" : var.control_plane_dsp_url
35 },
36
37 "logging" : <<EOT
38 .level=DEBUG
39 org.eclipse.edc.level=ALL
40 handlers=java.util.logging.ConsoleHandler
41 java.util.logging.ConsoleHandler.formatter=java.util.logging.SimpleFormatter
42 java.util.logging.ConsoleHandler.level=ALL
43 java.util.logging.SimpleFormatter.format=[%1$tY-%1$tm-%1$td %1$tH:%1$tM:%1$tS] [%4$-7s] %5$s%6$s%n
44 EOT
45
46 "config" : <<EOT
47edc.vault.hashicorp.token.scheduled-renew-enabled=false
48edc.negotiation.state-machine.iteration-wait-millis=${var.negotiation_state_machine_wait_millis}
49edc.transfer.state-machine.iteration-wait-millis=${var.transfer_state_machine_wait_millis}
50edc.policy.monitor.state-machine.iteration-wait-millis=${var.policy_monitor_state_machine_wait_millis}
51 EOT
52
53 "ingress" : {
54 "enabled" : true
55 "className" : "nginx"
56 "annotations" : {
57 "nginx.ingress.kubernetes.io/ssl-redirect" : "false"
58 "nginx.ingress.kubernetes.io/use-regex" : "true"
59 "nginx.ingress.kubernetes.io/rewrite-target" : "/api/$1$2"
60 },
61 "endpoints" : [
62 {
63 "port" : 8181,
64 "path" : "/cp/(management)(.*)"
65 },
66 {
67 "port" : 8282,
68 "path" : "/cp/(dsp)(.*)"
69 }
70 ]
71 },
72 "postgresql" : {
73 "jdbcUrl" : "jdbc:postgresql://${var.db_server_fqdn}/${var.db_name}",
74 "credentials" : {
75 "secret" : {
76 "name" : kubernetes_secret.db-user-credentials.metadata.0.name
77 }
78 }
79 },
80 "vault" : {
81 "hashicorp" : {
82 "url" : var.vault_url
83 "token" : {
84 "secret" : {
85 "name" : var.vault_token_secret_name
86 }
87 }
88 }
89 }
90 }
91 })
92 ]
93
94 depends_on = [module.db]
95}