-
Notifications
You must be signed in to change notification settings - Fork 224
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Non-git directories should error on tags #769
Comments
I get exit code 1 on failure as you described it:
it returns 1 isn't this the proposed solution? |
@martindekov So I went back and took a look at our pipeline, turns out we built on one machine (with the correct git version) and deployed on one that ended up with the zip, looks like |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
This happened because of an edge case with a git binary version on a self-hosted runner.
When using tags of branch or sha on a directory that isn't a git repository, you get a complete error as an image name, e.g;
eu.gcr.io/project/image:0.1-fatal: not a git repository (or any parent up to mount point /github) Stopping at filesystem boundary (GIT_DISCOVERY_ACROSS_FILESYSTEM not set).-fatal: not a git repository (or any parent up to mount point /github) Stopping at filesystem boundary (GIT_DISCOVERY_ACROSS_FILESYSTEM not set).
This is an invalid image name, and kubernetes had some issues with this.
Expected Behaviour
Should fatal or exit back to the user (with a non zero exit code)
Current Behaviour
Creates invalid image names
Possible Solution
Exit with a non-zero exit code (so that a pipeline can exit too, in this case, the runner had checked the code out as a zip instead of git without any notice)
Steps to Reproduce (for bugs)
faas-cli build --parallel 5 --tag=sha -f faas-stack.yml
on a non-git directoryContext
Runner had changed the checkout method without notification
The text was updated successfully, but these errors were encountered: