-
Notifications
You must be signed in to change notification settings - Fork 644
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
docker-save support #687
docker-save support #687
Conversation
Codecov Report
@@ Coverage Diff @@
## master #687 +/- ##
============================================
+ Coverage 47.48% 47.52% +0.03%
- Complexity 1002 1023 +21
============================================
Files 125 126 +1
Lines 6596 6694 +98
Branches 847 870 +23
============================================
+ Hits 3132 3181 +49
- Misses 3196 3241 +45
- Partials 268 272 +4
Continue to review full report at Codecov.
|
Thanks for the PR and sorry for the delay ! I hope I will have a chance to look at it soon. |
Sorry again for the delay, but should be added soon ;-) Your PR looks good, I tuned it a bit. Especially its allowed now to run
What is still missing is documentation. As soon as we have this, we can merge it. When you feel fancy, feel free to submit some documentation. But I can update it, too. Also some extra unit tests would be awesome (e.g. for |
* Allow an no-argument call to docker:save by chosing sane defaults * Reused ArchiveCompression for selecting the compression mode and a bit more
02db086
to
d9939ca
Compare
I'd probably prefer |
Thanks a lot, I will have a look at the weekend and will integrate the PR. |
Signed-off-by: Stas Sukhanov <stas.sukhanov@gmail.com>
Signed-off-by: Stas Sukhanov <stas.sukhanov@gmail.com>
PR merged! Thanks!
This implies adding a ':latest' when no tag was given in the image configuration. Fixes fabric8io#737
PR merged! Thanks!
Otherwise no build configuration will be created. This fixes fabric8io#736. Also made error messages a bit more verbose.
PR merged! Thanks!
…oka/docker-maven-plugin into pr/Katsuya-Tomioka-docker-save-support
In any other usage scenarios Also, we need to sanitise the name as it can contain |
if (classifier != null) { | ||
projectHelper.attachArtifact(project, type, classifier, fileObj); | ||
} else { | ||
projectHelper.attachArtifact(project, type, fileObj); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We should not do this here, as it will replace the main artefact of the build when no classifier is used.
From the JavaDoc:
Add or replace an artifact to the current project.
and with classifier == null it will replace the main artefact.
I suggest to remove this feature for now and, if needed for a specific use case, introduce it again.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Also I don't think attaching an image like this make sense, as it's probably really huge and your Maven repo (either local or remote) won't cope with suche multi hundred mega byte tars for every version of your artefact.
@@ -65,6 +65,11 @@ public String deleteImage(String name, boolean force) { | |||
.build(); | |||
} | |||
|
|||
public String getImage(ImageName name) { | |||
return u("images/%s/get", name.getNameWithoutTag()) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't think we should use the name without tag because according to the Docker reference manual in that case all image of all tags are returned. Actually we should use the full image name here.
* Removed attaching of artifacts as they are too huge anyway * Harmonized properties name to be more specific * Added a bit to documentation * Fixed fetching of all images by using the full name
I updated the PR according to my comments, if you don't mind. Going to merge this into master now, we can still tune it before doing the next release. Thanks a lot for you contribution ! 'hope my updates are fine for you. |
[merge] |
…port PR merged! Thanks!
I wrote to specify which one (and where) to save rather than go over build configs as in 'source'. Also not sure about where to autopull. Seemed too much in this context. Let me know.