Closed vishweshwarp closed 6 years ago
Found the root cause.
As per Kubernetes documentation, https://kubernetes.io/docs/tasks/access-application-cluster/configure-access-multiple-clusters/#set-the-kubeconfig-environment-variable
The KUBECONFIG environment variable is a list of paths to configuration files. The list is colon-delimited for Linux and Mac, and semicolon-delimited for Windows.
At line 29 in "serverless-kubeless/lib/helpers.js" file, we are splitting KUBECONFIG paths list with hard coded colon. Due to this Windows paths are split incorrectly at drive colon character (C:).
const configFiles = process.env.KUBECONFIG.split(':');
When I added made delimiter conditional based on OS in my local helpers.js file, functions got deployed to Kubeless successfully.
Will submit this fix for review.
Wow, great find @vishweshwarp Thanks for posting the solution and contributing it back to the repository.
Our team will take a look at your PR soon. Thanks again :+1:
Thanks @vishweshwarp for the fix 👍 . The PR is good to be landed.
Commands executed:
Error log:
Error says
But there is no directory with name "\C" under cloned example "serverless-kubeless\examples\get-python" directory.
I am using Kubeless version v0.3.1 on Kubernetes. Everything works fine if I directly create functions on Kubeless.