blob: 71450a1bf5b56206623b47dea1d35c88423b3dab [file] [log] [blame]
package kube
Component :: "kitchen"
deployment <Name> spec template: {
metadata annotations "prometheus.io.scrape": "true"
spec containers: [{
ports: [{
containerPort: 8080
}]
livenessProbe: {
httpGet: {
path: "/debug/health"
port: 8080
}
initialDelaySeconds: 40
periodSeconds: 3
}
}]
}
deployment <ID> spec template spec: {
hasDisks :: *true | bool
// field comprehension using just "if"
if hasDisks {
volumes: [{
name: *"\(ID)-disk" | string
gcePersistentDisk pdName: *"\(ID)-disk" | string
gcePersistentDisk fsType: "ext4"
}, {
name: *"secret-\(ID)" | string
secret secretName: *"\(ID)-secrets" | string
}, ...]
containers: [{
volumeMounts: [{
name: *"\(ID)-disk" | string
mountPath: *"/logs" | string
}, {
mountPath: *"/etc/certs" | string
name: *"secret-\(ID)" | string
readOnly: true
}, ...]
}]
}
}