@ -62,6 +62,9 @@
// Set to true to let the ingress handle TLS
// Set to true to let the ingress handle TLS
ingress_tls: true,
ingress_tls: true,
// Ingress class for ingress
ingress_class_name: "nginx",
// Uncomment and give a secretName for ingress, if required for ingress TLS
// Uncomment and give a secretName for ingress, if required for ingress TLS
//ingress_secret_name: "wubloader-tls",
//ingress_secret_name: "wubloader-tls",
@ -308,12 +311,13 @@
// Ingress to direct requests to the correct services.
// Ingress to direct requests to the correct services.
{
{
kind: "Ingress",
kind: "Ingress",
apiVersion: "networking.k8s.io/v1beta1 ",
apiVersion: "networking.k8s.io/v1",
metadata: {
metadata: {
name: "wubloader",
name: "wubloader",
labels: {app: "wubloader"} + $.config.ingress_labels,
labels: {app: "wubloader"} + $.config.ingress_labels,
},
},
spec: {
spec: {
ingressClassName: $.config.ingress_class_name,
rules: [
rules: [
{
{
host: $.config.ingress_host,
host: $.config.ingress_host,
@ -323,8 +327,12 @@
path: path,
path: path,
pathType: type,
pathType: type,
backend: {
backend: {
serviceName: "wubloader-%s" % std.strReplace(name, "_", "-"),
service: {
servicePort: 80,
name: "wubloader-%s" % std.strReplace(name, "_", "-"),
port: {
number: 80
},
},
},
},
},
},
local metric_rule(name) = rule(name, "/metrics/%s" % name, "Exact"),
local metric_rule(name) = rule(name, "/metrics/%s" % name, "Exact"),