Skip to content
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

add BRANCH_NAME even if git is missing #74

Open
NikolayMetchev opened this issue Jul 12, 2022 · 3 comments
Open

add BRANCH_NAME even if git is missing #74

NikolayMetchev opened this issue Jul 12, 2022 · 3 comments

Comments

@NikolayMetchev
Copy link

We are using the k8s plugin in Jenkins which runs gradle in a docker container that doesn't have git installed. This means that the BRANCH name is no longer added as a tag. It would be good if this was fixed so that even if git is not installed the BRANCH_NAME env variable is still added as a tag.

@runningcode
Copy link
Contributor

This is the default behavior. See the code here

However in your specific case, since you are running the build inside the docker container, can you make sure that these environment variables are also available inside your docker container?

@NikolayMetchev
Copy link
Author

Hi Nelson,
BRANCH_NAME is available inside the container but it doesn't get added as a tag, this is because the code you pointed to only runs if git is available.

@runningcode
Copy link
Contributor

Ah, thanks for finding that. We'll look in to this.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants