Sha256: ee4772aed1e4e1fd438f5824fa5a943d1a87904579ebb1280547a2776df83007
Contents?: true
Size: 960 Bytes
Versions: 3
Compression:
Stored size: 960 Bytes
Contents
--- title: Kubes YAML --- You can write your Kubernetes resources in YAML format. .kubes └── resources └── web ├── deployment.yaml └── service.yaml ## YAML and Templating Kubes provides a little extra power for the YAML format. The YAML files are processed through an ERB templating language. So you have dynamic control. Here's an example with `Kubes.env` and the `built_image` helper. .kubes/resources/web/deployment.yaml ```yaml --- apiVersion: apps/v1 kind: Deployment metadata: name: demo-web labels: app: demo namespace: default spec: replicas: <%= Kubes.env == "prod" ? 2 : 1 %> selector: matchLabels: app: demo strategy: rollingUpdate: maxSurge: 25 maxUnavailable: 25 type: RollingUpdate template: metadata: labels: app: demo spec: containers: - name: demo-web image: <%= built_image %> ```
Version data entries
3 entries across 3 versions & 1 rubygems
Version | Path |
---|---|
kubes-0.2.2 | docs/_docs/yaml.md |
kubes-0.2.1 | docs/_docs/yaml.md |
kubes-0.2.0 | docs/_docs/yaml.md |