about summary refs log tree commit diff
path: root/example/some-api/some-api.yaml
diff options
context:
space:
mode:
authorNiklas Wik <niklas.wik@nokia.com>2018-01-09T13·12+0200
committerVincent Ambo <github@tazj.in>2018-03-09T13·54+0100
commitbafb792339b5898a0e6b6219ad54b5f501d727c2 (patch)
tree1b364cfb260ddc24642c64ad0e17c1ac486dac58 /example/some-api/some-api.yaml
parent850fdcf3e0270db885f661ae59225db92143c3f2 (diff)
feat(templater): Added support for file include
Adds a 'fileContent' template function to insert the literal contents
of a file specified in the template.

Signed-off-by: Niklas Wik <niklas.wik@nokia.com>
Diffstat (limited to 'example/some-api/some-api.yaml')
-rw-r--r--example/some-api/some-api.yaml2
1 files changed, 2 insertions, 0 deletions
diff --git a/example/some-api/some-api.yaml b/example/some-api/some-api.yaml
index 57ab7c65275d..44b61541744c 100644
--- a/example/some-api/some-api.yaml
+++ b/example/some-api/some-api.yaml
@@ -25,6 +25,8 @@ spec:
               value: {{ .importantFeature }}
             - name: SOME_GLOBAL_VAR
               value: {{ .globalVar }}
+            - name: FILE_VAR
+              value: {{ fileContent "some-api/filevar.txt" }}
 ---
 apiVersion: v1
 kind: Service