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

Pull --debug fix on docker:// URI #1556

Merged
merged 2 commits into from
May 22, 2018
Merged

Pull --debug fix on docker:// URI #1556

merged 2 commits into from
May 22, 2018

Conversation

jmstover
Copy link
Contributor

Description of the Pull Request (PR):

When we pull from a docker:// URI, we aren't passing the debug flag if it was used. Check SINGULARITY_MESSAGELEVEL, and if 5 (debug), pass the -d flag to the singularity build

This fixes or addresses the following GitHub issues:

Checkoff for all PRs:

  • I have read the Guidelines for Contributing, and this PR conforms to the stated requirements.
  • [] I have added changes to the CHANGELOG and and documentation updates to the singularityware documentation base.
  • [] I have tested this PR locally with a make test
  • This PR is NOT against the project's master branch
  • [] I have added myself as a contributor to the contributors's file
  • This PR is ready for review and/or merge

Attn: @singularityware-admin

Fix pull on a docker:// URI, so if debug (-d) is passed, we
pass the debug flag when we run the `singularity build`
command.
@jmstover jmstover changed the base branch from master to development-2.x May 17, 2018 21:28
if [ -x "${SINGULARITY_bindir}/singularity" ]; then
${SINGULARITY_bindir}/singularity build ${SINGULARITY_IMAGE} ${SINGULARITY_CONTAINER}
DBGFLAG=""
if [ "x${SINGULARITY_MESSAGELEVEL}" == "x5" ]; then
Copy link
Contributor

@bauerm97 bauerm97 May 21, 2018

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why does this say "x$... and "x5" instead of "$... and "5"?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Because if SINGULARITY_MESSAGELEVEL is not set, you could end up like:

if [ == 5 ]; then

And not have a left hand side. So ... it's common practice to add an x in, so the check ends up as:

if [ x == x5 ]; then

Copy link
Contributor

@dtrudg dtrudg left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This looks good to me - will assist in turnaround on issues 👍

@jmstover jmstover merged commit d8e49cb into apptainer:development-2.x May 22, 2018
GodloveD pushed a commit that referenced this pull request May 22, 2018
Pull --debug fix on docker:// URI
@jmstover jmstover deleted the pull_debug_fix branch May 22, 2018 20:44
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

Successfully merging this pull request may close these issues.

3 participants