From 8fac7c1a415d6ea5e41c28f4e7ab5c1ef0883997 Mon Sep 17 00:00:00 2001 From: Vincent Ambo Date: Wed, 8 Feb 2017 11:55:59 +0100 Subject: chore: Better example & gofmt --- example/prod-cluster.json | 2 +- example/some-api/deployment.yaml | 0 example/some-api/service.yaml | 5 ----- example/some-api/some-api.yaml | 34 ++++++++++++++++++++++++++++++++++ 4 files changed, 35 insertions(+), 6 deletions(-) delete mode 100644 example/some-api/deployment.yaml delete mode 100644 example/some-api/service.yaml create mode 100644 example/some-api/some-api.yaml (limited to 'example') diff --git a/example/prod-cluster.json b/example/prod-cluster.json index 76246ca382de..70e2365f1710 100644 --- a/example/prod-cluster.json +++ b/example/prod-cluster.json @@ -1,7 +1,7 @@ { "context": "k8s.prod.mydomain.com", "global": { - "globalTest": "lizards" + "globalVar": "lizards" }, "include": [ { diff --git a/example/some-api/deployment.yaml b/example/some-api/deployment.yaml deleted file mode 100644 index e69de29bb2d1..000000000000 diff --git a/example/some-api/service.yaml b/example/some-api/service.yaml deleted file mode 100644 index 6aee8788093c..000000000000 --- a/example/some-api/service.yaml +++ /dev/null @@ -1,5 +0,0 @@ ---- -name: foo -importantFeature: {{ .importantFeature }} -port: {{ .apiPort }} -globalTest: {{ .globalTest }} diff --git a/example/some-api/some-api.yaml b/example/some-api/some-api.yaml new file mode 100644 index 000000000000..6f6a29a1599a --- /dev/null +++ b/example/some-api/some-api.yaml @@ -0,0 +1,34 @@ +--- +apiVersion: extensions/v1beta1 +kind: Deployment +metadata: + name: some-api +spec: + replicas: 1 + template: + metadata: + labels: + app: some-api + spec: + containers: + - image: my.container.repo/some-api:{{ .version }} + name: some-api + env: + - name: ENABLE_IMPORTANT_FEATURE + value: {{ .importantFeature }} + - name: SOME_GLOBAL_VAR + value: {{ .globalVar }} +--- +apiVersion: v1 +kind: Service +metadata: + name: some-api + labels: + app: some-api +spec: + selector: + app: some-api + ports: + - port: 80 + targetPort: {{ .apiPort }} + name: http -- cgit 1.4.1