Tags: ndsun/faas-cli
Tags
Ensure that we name the copy dest correctly **What** - When we iterate through function handler, we need to name the destination with the file/folder name we are currrently inspecting - Clean the file path before we give it to CopyFiles **Why** - This ensures that we copy the file _into_ the build folder and don't try to read it ontop of the folder Signed-off-by: Lucas Roesler <roesler.lucas@gmail.com>
Fixes openfaas#518 sending auth secrets on invoke Auth secrets were being sent since auth was introduced in the CLI 10 months ago. This is problematic for two reasons: 1) there is no auth enabled on the function endpoints, 2) this could expose the system authentication secrets to functions which is undesired. Signed-off-by: Alex Ellis (VMware) <alexellis2@gmail.com>
Add unit tests for generate command This commit add unit tests for `generate` verb of faas-cli. This also refactors some of the code for `generate` verb. Fixes: openfaas#492 Signed-off-by: Vivek Singh <vivekkmr45@yahoo.in>
Rename r/o FS flag in schema The YAML schema has an incorrect naming for YAML using camelCase, this PR updates the naming to "readonly_root_filesystem" which is more consistent with existing code and YAML naming. Signed-off-by: Alex Ellis (VMware) <alexellis2@gmail.com>
Implement Golang template for stack file Append `latest` tag to all newly created functions. This fixes a bug where images being pushed without a tag will update all tags of the image. Now, only the current tag will be pushed. Fix is implemented with Golang template to allow for greater flexibility. Fixes: openfaas/faas#779 Signed-off-by: James Smith <jamessmithsmusic@gmail.com>
Fix registry auth for Gitlab subdir images
This commit fixes the getRegistryAuth function so that it works
correctly with images that exist in subdirs on custom docker registries,
for example Gitlab.
Before this change the following image works as expected:
registry.gitlab.com/johnmccabe/myfunctions
But a imaged nested under that namespace would fail to find any auth
from the docker cached creds, for example this would fail:
registry.gitlab.com/johnmccabe/myfunctions/coolfn
This fix address the underlying issue in the registry domain extraction
so that both cases now work, I've tested with private registries on
both Gitlab and Docker Hub successfully.
Have also added a test to catch the nested subdir image case.
Signed-off-by: John McCabe <john@johnmccabe.net>