openwhisk-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From chet...@apache.org
Subject [openwhisk-deploy-kube] branch master updated: Refactor invoker env templates (#516)
Date Fri, 30 Aug 2019 05:01:15 GMT
This is an automated email from the ASF dual-hosted git repository.

chetanm pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/openwhisk-deploy-kube.git


The following commit(s) were added to refs/heads/master by this push:
     new 05591c7  Refactor invoker env templates (#516)
05591c7 is described below

commit 05591c7ef13372c9c0efcbbc62c66f4c56f4affd
Author: David Grove <dgrove-oss@users.noreply.github.com>
AuthorDate: Fri Aug 30 01:01:09 2019 -0400

    Refactor invoker env templates (#516)
    
    Breaks the apihost macro into two macros so that intent of each is clear.
---
 helm/openwhisk/templates/_helpers.tpl        | 4 ++++
 helm/openwhisk/templates/controller-pod.yaml | 1 +
 helm/openwhisk/templates/invoker-pod.yaml    | 3 +++
 3 files changed, 8 insertions(+)

diff --git a/helm/openwhisk/templates/_helpers.tpl b/helm/openwhisk/templates/_helpers.tpl
index 96a192d..095d2bd 100644
--- a/helm/openwhisk/templates/_helpers.tpl
+++ b/helm/openwhisk/templates/_helpers.tpl
@@ -269,6 +269,10 @@ imagePullSecrets:
     configMapKeyRef:
       name: {{ .Release.Name }}-whisk.config
       key: whisk_api_host_name
+{{- end -}}
+
+{{/* Environment variables required for invoker containerpool/containerfactory configuration
*/}}
+{{- define "openwhisk.invoker.containerconfig" -}}
 - name: "CONFIG_whisk_docker_containerFactory_useRunc"
   value: {{ .Values.invoker.containerFactory.useRunc | quote }}
 - name: "CONFIG_whisk_containerPool_userMemory"
diff --git a/helm/openwhisk/templates/controller-pod.yaml b/helm/openwhisk/templates/controller-pod.yaml
index abbaedc..e4914ee 100644
--- a/helm/openwhisk/templates/controller-pod.yaml
+++ b/helm/openwhisk/templates/controller-pod.yaml
@@ -180,4 +180,5 @@ spec:
 
 {{- if .Values.controller.lean }}
 {{ include "openwhisk.invoker.apihost" . | indent 8 }}
+{{ include "openwhisk.invoker.containerconfig" . | indent 8 }}
 {{- end }}
diff --git a/helm/openwhisk/templates/invoker-pod.yaml b/helm/openwhisk/templates/invoker-pod.yaml
index 2184351..3a2b481 100644
--- a/helm/openwhisk/templates/invoker-pod.yaml
+++ b/helm/openwhisk/templates/invoker-pod.yaml
@@ -86,6 +86,9 @@ spec:
           # Needed by invoker to set the environment variable __OW_API_HOST in action containers
 {{ include "openwhisk.invoker.apihost" . | indent 10 }}
 
+          # Needed by invoker to configure the container factory & container pool
+{{ include "openwhisk.invoker.containerconfig" . | indent 10 }}
+
 {{- if not .Values.invoker.containerFactory.networkConfig.dns.inheritInvokerConfig }}
 {{- if ne .Values.invoker.containerFactory.networkConfig.dns.overrides.nameservers "" }}
           # DNS Server(s) to be used by action containers


Mime
View raw message