docker-maven-plugin icon indicating copy to clipboard operation
docker-maven-plugin copied to clipboard

fix: support skipping tags

Open nodece opened this issue 1 year ago • 3 comments

Motivation

I'm using the buildx to build the multiple-arch images, when I use -Ddocker.skip.tag=true to skip the tag, this plugin still tags the image.

Changes

  • Add skip tag to the image level by <skipTag>
  • When the skip tag is true, the plugin will not tag the image on the build and buildx stage

Doc

The previous document included <skipTag>, so I did not add the document.

nodece avatar May 17 '24 18:05 nodece

@rohanKanojia Thank you for your review, this PR has been updated, could you review this PR again?

nodece avatar May 19 '24 16:05 nodece

MacOS ci failed, what do you suggest, it seems to be unable to pull pg image.

nodece avatar May 19 '24 17:05 nodece

@nodece : Could you please address Sonar Code smells that seem applicable?

rohanKanojia avatar May 20 '24 12:05 rohanKanojia

@rohanKanojia Done.

nodece avatar May 20 '24 14:05 nodece

should I upgrade the postgres image? It looks blocked my PR.

nodece avatar May 20 '24 14:05 nodece

@nodece : Could you please rebase this one?

rohanKanojia avatar May 21 '24 18:05 rohanKanojia

@nodece : Thanks, looks good to be merged. Only thing I see missing is documentation. Could you please add documentation for this new field skipTags in plugin and image build configuration?

Could you also add an entry for this change in doc/changelog.md?

rohanKanojia avatar May 24 '24 16:05 rohanKanojia

@nodece : Thanks, looks good to be merged. Only thing I see missing is documentation. Could you please add documentation for this new field skipTags in plugin and image build configuration?

Please see the PR description, I can also add the more description about when tag the image.

Could you also add an entry for this change in doc/changelog.md?

I can add skipTag parameter description to the changlong.

nodece avatar May 24 '24 16:05 nodece

You're right. Documentation is already there for plugin configuration skipTag but I think we need to add it for image level skipTag.

rohanKanojia avatar May 24 '24 17:05 rohanKanojia

You're right. Documentation is already there for plugin configuration skipTag but I think we need to add it for image level skipTag.

The skipTag parameter exists in the plugin configuration and image levels(docker:build), could you check this documentation?

Please see https://dmp.fabric8.io/#build-configuration

nodece avatar May 24 '24 17:05 nodece

@nodece : oh, that's quite strange. I see that this field got added in this PR.

rohanKanojia avatar May 25 '24 03:05 rohanKanojia

The documentation was wrongly added in https://github.com/fabric8io/docker-maven-plugin/pull/954

rohanKanojia avatar May 25 '24 10:05 rohanKanojia