CLI fix offline command save stacks to tars #5269
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
What does this PR do?
fixes two issues related to CLI offline mode during stack images saving
first issue:
if image name has more than 1
/
symbol likeregistry.centos.org/che-stacks/vertx
save to tar will fail:to fix this I;ve updated
sed
pattern to replace all/
symbols with_
second issue:
if
images-stacks
file has any empty line like this https://github.com/eclipse/che/blob/master/dockerfiles/cli/version/5.11.2/images-stacks#L24that will cause an error during iterating over array which is made from that file:
to fix this I;ve added check on empty strings:
What issues does this PR fix or reference?
#5268
Changelog
CLI fix offline command save stacks to tars