dgrove-oss closed pull request #172: test both DockerContainerFactory and 
KubernetesContainerFactory
URL: https://github.com/apache/incubator-openwhisk-deploy-kube/pull/172
 
 
   

This is a PR merged from a forked repository.
As GitHub hides the original diff on merge, it is displayed below for
the sake of provenance:

As this is a foreign pull request (from a fork), the diff is supplied
below (as it won't show otherwise due to GitHub magic):

diff --git a/.travis.yml b/.travis.yml
index 2c91ef9..584f4bb 100644
--- a/.travis.yml
+++ b/.travis.yml
@@ -6,6 +6,9 @@ env:
   - TRAVIS_MINIKUBE_VERSION=v0.23.0
   - secure: 
d7CuMXbhT83W2x78qiLwgogX1+3aPicd1PlTwwNNDN6QSkImbxareyKThnsqlHIiNj3o5l5DBuiYjy7wrF/xD1g8BQMmTwm99DRx5q3CI3Im3VCi/ZK8SaNjuOy24d7cf5k2tB/87Gk7zmKsMDYm+fpCl+GpgUmIEeIwthiAxuXSDWZ8eQPIptmxj56DeFRNouvXG+dEUtBfWiwN27UPxNKExCixFnegmdtffLbz6hhst7BHr5Ry9acbycre98PCwWZcu9lxFs+SJ1kvnzX2iue4otmDkF1WkJjxaOFPJVs/D3YItg+neLCSxjwBskPed+Fct8bOjcM/uVROJPNIq5icBmaPX2isH0lvtxOeVw/dmioWYXYPN9ygBOe4eO/vtPllN0bcAUo5xl9jXev8ciAozYrYpHVh9Fplfd81rcYTeYzALmRJBdoiWoc3KQGzwGc9sB1ffmy+KWgG9T0zbnS4fALSR4PSzyNlKSLXw9vuvdNP0OBYtO+6yTJXavIxqmDoj64Lb93n+uGPatnaIGPTKEEBMJTSjsgYVEfxzzZuxUT9Ldkf2lzqvN2PCllGoMqxkgsdb8i4v4QgRaMWBDbKa5Va4k0O4dnhRmtdbJavOSKN6fECJbyfoJlV1VvJGxk5znVLRznBmUPBKbNccyPZJULugKD3QIh4q8Q5jBU=
   - secure: 
CJtnU94HTDqd4A6uvhFl8IpnmU+wTdlzb8bPBFUl/lI/VKXiRrYpgJdKUro5xEoxFKuqMprLhbyf66niyWLTIeogjUAEu/h/o2dBVeGgSGKoqC0hQgqvnxKFeGlzFJ0XuEs3vbStJGRnQszGsfnnDrscJtR0x9X+1w4aBKI7iPyyuFtVkDD1UsmBbSi+M8FTeq7G7A0reMDaey7uog3CFCpIMl4geshcohQEcKEGbnXQZoLPFpb7cBOE83VXBJ7Y7Dgf/U4keiLovvnuJThGKZm/SVV2KlELmBmtmbx3rMT6Vb5k9ChSdRWapromNnnzmJBIQ5Scc2mwV3A93/SMha1F3IlYpDKs5djfTw8jZfVnuiou7HhTaRjHkmmcwP12/k30gLe2kw0Vezg1TCY4zgtOpcmCxc8RHEy0ceA74rKvRi8LbexTCwX+iAMQFn/pSrh/OqAq/50JbLyczcoO1zXWS38txUQNLW8i+XllhCg9pjkjyfBeGjOOcWiVIz9rWJd2XufjSXDcj6xoZHtkh1XDt1CnVkpsYKtyyZucQnhUM9ebmaWqbSW2+bpqC/2hI+G+kOyyCesGdB1q+VmN1augMMs6RgWjk4yw5dyLAshATSoUlE8KH2cDcJL19r4ECaQ99PSLwxoB89yfPoJiNc42vwxRdsLmB1BMNyPa81Y=
+  matrix:
+    - OW_CONTAINER_FACTORY=docker
+    - OW_CONTAINER_FACTORY=kube
 
 services:
   - docker
diff --git a/kubernetes/invoker/invoker-k8scf.yml 
b/kubernetes/invoker/invoker-k8scf.yml
index 7c5129c..334c6b6 100644
--- a/kubernetes/invoker/invoker-k8scf.yml
+++ b/kubernetes/invoker/invoker-k8scf.yml
@@ -1,6 +1,7 @@
 apiVersion: v1
 kind: ServiceAccount
 metadata:
+  namespace: openwhisk
   name: invoker
 
 ---
diff --git a/tools/travis/build.sh b/tools/travis/build.sh
index 8feaceb..fd14dba 100755
--- a/tools/travis/build.sh
+++ b/tools/travis/build.sh
@@ -210,13 +210,23 @@ pushd kubernetes/controller
 popd
 
 # setup the invoker
-echo "Deploying invoker using DockerContainerFactory"
 pushd kubernetes/invoker
-  kubectl -n openwhisk create cm invoker.config --from-env-file=invoker-dcf.env
-  kubectl apply -f invoker-dcf.yml
-
-  # wait until the invoker is ready
-  deploymentHealthCheck "invoker"
+    if [ "$OW_CONTAINER_FACTORY" = "docker" ]; then
+        echo "Deploying invoker using DockerContainerFactory"
+        kubectl -n openwhisk create cm invoker.config 
--from-env-file=invoker-dcf.env
+        kubectl apply -f invoker-dcf.yml
+        deploymentHealthCheck "invoker"
+    elif [ "$OW_CONTAINER_FACTORY" = "kube" ]; then
+        echo "Deploying invoker using KubernetesContainerFactory"
+        kubectl -n openwhisk create cm invoker.config 
--from-env-file=invoker-k8scf.env
+        kubectl apply -f invoker-agent.yml
+        deploymentHealthCheck "invoker-agent"
+        kubectl apply -f invoker-k8scf.yml
+        deploymentHealthCheck "invoker-0"
+    else
+        echo "Unknown container factory $OW_CONTAINER_FACTORY"
+        exit 1
+    fi
 popd
 
 # setup nginx


 

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


With regards,
Apache Git Services

Reply via email to