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

s2i steps default to git ref "master", but not all git repositories have a master branch #49

Open
jmtd opened this issue Nov 8, 2023 · 0 comments

Comments

@jmtd
Copy link
Collaborator

jmtd commented Nov 8, 2023

In the absence of an explicit ref in the step "Given s2i build...", i.e., Given s2i build https://...somerepo.../ with no using branchname suffix, the S2I steps will default to try to check out a branch named master, which may not exist in the repository.

Instead I think it should use the repository's default branch name.

We hit this (side issue) by introducing a new repository for cekit/behave tests, https://github.com/jboss-container-images/openjdk-test-applications, which has the default branch name main. This is the new default, I think, for both Git and Github. (At the time of writing this, I'm about to push a master branch to that repository as a temporary mitigation).

The culprits are

def s2i_inner(context, application, path='.', env="", incremental=False, tag="master", runtime_image=""):

and
def s2i_build(context, application, path='.', env="", incremental=False, tag="master", run=True, runtime_image=""):

and possibly a few other places.

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

1 participant