add stirling-pdf because why not [ci skip]
This commit is contained in:
parent
bcc4990096
commit
3e7b150779
3 changed files with 97 additions and 2 deletions
89
modules/kubernetes/stirling-pdf/main.tf
Normal file
89
modules/kubernetes/stirling-pdf/main.tf
Normal file
|
|
@ -0,0 +1,89 @@
|
|||
variable "tls_secret_name" {}
|
||||
|
||||
resource "kubernetes_namespace" "stirling-pdf" {
|
||||
metadata {
|
||||
name = "stirling-pdf"
|
||||
labels = {
|
||||
"istio-injection" : "disabled"
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
module "tls_secret" {
|
||||
source = "../setup_tls_secret"
|
||||
namespace = "stirling-pdf"
|
||||
tls_secret_name = var.tls_secret_name
|
||||
}
|
||||
|
||||
resource "kubernetes_deployment" "stirling-pdf" {
|
||||
metadata {
|
||||
name = "stirling-pdf"
|
||||
namespace = "stirling-pdf"
|
||||
labels = {
|
||||
app = "stirling-pdf"
|
||||
}
|
||||
}
|
||||
spec {
|
||||
replicas = 1
|
||||
selector {
|
||||
match_labels = {
|
||||
app = "stirling-pdf"
|
||||
}
|
||||
}
|
||||
template {
|
||||
metadata {
|
||||
labels = {
|
||||
app = "stirling-pdf"
|
||||
}
|
||||
}
|
||||
spec {
|
||||
container {
|
||||
image = "stirlingtools/stirling-pdf:latest"
|
||||
name = "stirling-pdf"
|
||||
port {
|
||||
container_port = 8080
|
||||
}
|
||||
volume_mount {
|
||||
name = "configs"
|
||||
mount_path = "/configs"
|
||||
}
|
||||
}
|
||||
volume {
|
||||
name = "configs"
|
||||
nfs {
|
||||
server = "10.0.10.15"
|
||||
path = "/mnt/main/stirling-pdf"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
resource "kubernetes_service" "stirling-pdf" {
|
||||
metadata {
|
||||
name = "stirling-pdf"
|
||||
namespace = "stirling-pdf"
|
||||
labels = {
|
||||
"app" = "stirling-pdf"
|
||||
}
|
||||
}
|
||||
|
||||
spec {
|
||||
selector = {
|
||||
app = "stirling-pdf"
|
||||
}
|
||||
port {
|
||||
name = "http"
|
||||
port = 80
|
||||
target_port = 8080
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
module "ingress" {
|
||||
source = "../ingress_factory"
|
||||
namespace = "stirling-pdf"
|
||||
name = "stirling-pdf"
|
||||
tls_secret_name = var.tls_secret_name
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue