mirror of
https://github.com/kittywitch/nixfiles.git
synced 2026-02-09 04:19:19 -08:00
[POSTGRES] Dependencies
This commit is contained in:
parent
ecbeb41ec9
commit
0a5dfcbde0
3 changed files with 6 additions and 22 deletions
2
.gitmodules
vendored
2
.gitmodules
vendored
|
|
@ -1,3 +1,3 @@
|
||||||
[submodule "lpp"]
|
[submodule "lpp"]
|
||||||
path = cluster/lpp
|
path = cluster/lpp
|
||||||
url = git@github.com:rancher/local-path-provisioner.git
|
url = https://github.com/rancher/local-path-provisioner.git
|
||||||
|
|
|
||||||
|
|
@ -1,7 +1,7 @@
|
||||||
resource "helm_release" "local_path_provisioner" {
|
resource "helm_release" "local_path_provisioner" {
|
||||||
name = "local-path-storage"
|
name = "local-path-provisioner"
|
||||||
repository = "./lpp"
|
repository = "${path.module}/lpp/deploy/chart"
|
||||||
chart = "local-path-storage"
|
chart = "local-path-provisioner"
|
||||||
create_namespace = true
|
create_namespace = true
|
||||||
namespace = "local-path-storage"
|
namespace = "local-path-storage"
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -23,22 +23,6 @@ resource "kubernetes_secret" "postgres_auth_secret" {
|
||||||
type = "Opaque"
|
type = "Opaque"
|
||||||
}
|
}
|
||||||
|
|
||||||
resource "kubernetes_persistent_volume_claim" "postgresql" {
|
|
||||||
metadata {
|
|
||||||
name = "prometheus-data"
|
|
||||||
namespace = "postgresql"
|
|
||||||
}
|
|
||||||
spec {
|
|
||||||
access_modes = [ "ReadWriteOnce" ]
|
|
||||||
resources {
|
|
||||||
requests = {
|
|
||||||
storage = "8Gi"
|
|
||||||
}
|
|
||||||
}
|
|
||||||
storage_class_name = "local-path"
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
resource "helm_release" "postgresql" {
|
resource "helm_release" "postgresql" {
|
||||||
depends_on = [
|
depends_on = [
|
||||||
kubernetes_namespace.postgres_namespace,
|
kubernetes_namespace.postgres_namespace,
|
||||||
|
|
@ -55,8 +39,8 @@ resource "helm_release" "postgresql" {
|
||||||
force_update = true
|
force_update = true
|
||||||
|
|
||||||
set {
|
set {
|
||||||
name = "persistence.existingClaim"
|
name = "global.storageClass"
|
||||||
value = kubernetes_persistent_volume_claim.postgresql.metadata[0].name
|
value = "local-path"
|
||||||
}
|
}
|
||||||
set {
|
set {
|
||||||
name = "global.postgresql.existingSecret"
|
name = "global.postgresql.existingSecret"
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue