feat(comfyui): add Dockerfile, playbook, and Terraform configurations for ComfyUI setup
This commit is contained in:
@@ -170,6 +170,7 @@ resource "kubernetes_ingress_v1" "reverse-proxy_ingress" {
|
||||
}
|
||||
|
||||
resource "kubernetes_secret" "auth_token" {
|
||||
count = var.auth_token != "" ? 1 : 0
|
||||
metadata {
|
||||
name = "auth-token-secret"
|
||||
namespace = kubernetes_namespace.reverse_proxy.metadata[0].name
|
||||
@@ -281,31 +282,34 @@ resource "kubernetes_deployment" "reverse_proxy" {
|
||||
}
|
||||
}
|
||||
|
||||
container {
|
||||
name = "auth-sidecar"
|
||||
image = "python:3.11-slim"
|
||||
dynamic "container" {
|
||||
for_each = var.auth_token != "" ? [1] : []
|
||||
content {
|
||||
name = "auth-sidecar"
|
||||
image = "python:3.11-slim"
|
||||
|
||||
command = ["python", "/app/auth_server.py"]
|
||||
command = ["python", "/app/auth_server.py"]
|
||||
|
||||
env {
|
||||
name = "AUTH_TOKEN"
|
||||
value_from {
|
||||
secret_key_ref {
|
||||
name = "auth-token-secret"
|
||||
key = "token"
|
||||
env {
|
||||
name = "AUTH_TOKEN"
|
||||
value_from {
|
||||
secret_key_ref {
|
||||
name = kubernetes_secret.auth_token[0].metadata[0].name
|
||||
key = "token"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
volume_mount {
|
||||
name = "auth-script"
|
||||
mount_path = "/app"
|
||||
read_only = true
|
||||
}
|
||||
volume_mount {
|
||||
name = "auth-script"
|
||||
mount_path = "/app"
|
||||
read_only = true
|
||||
}
|
||||
|
||||
port {
|
||||
container_port = 5000
|
||||
name = "auth"
|
||||
port {
|
||||
container_port = 5000
|
||||
name = "auth"
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user