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

[fix][build] Fix problem where git.commit.id.abbrev is missing in image tagging #23337

Merged
merged 1 commit into from
Sep 23, 2024

Conversation

lhotari
Copy link
Member

@lhotari lhotari commented Sep 23, 2024

Motivation

building a docker image with this command will fail.

mvn package -Pdocker,-main -am -pl docker/pulsar -DskipTests

error message is

[ERROR] Failed to execute goal io.fabric8:docker-maven-plugin:0.45.0:build (default) on project pulsar-docker-image: Execution default of goal io.fabric8:docker-maven-plugin:0.45.0:build failed: Given Docker name 'apachepulsar/pulsar:4.0.0-SNAPSHOT-${git.commit.id.abbrev}' is invalid:
[ERROR]    * tag part '4.0.0-SNAPSHOT-${git.commit.id.abbrev}' doesn't match allowed pattern '^[\w][\w.-]{0,127}$'
[ERROR] See http://bit.ly/docker_image_fmt for more details

Modifications

Fix the problem by revisiting the git-commit-id-plugin configuration in docker/pom.xml file.
Removing <runOnlyOnce>true</runOnlyOnce> fixes the problem.

Documentation

  • doc
  • doc-required
  • doc-not-needed
  • doc-complete

@lhotari lhotari added this to the 4.0.0 milestone Sep 23, 2024
@lhotari lhotari self-assigned this Sep 23, 2024
@github-actions github-actions bot added the doc-not-needed Your PR changes do not impact docs label Sep 23, 2024
@codecov-commenter
Copy link

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 74.53%. Comparing base (bbc6224) to head (4560bbf).
Report is 596 commits behind head on master.

Additional details and impacted files

Impacted file tree graph

@@             Coverage Diff              @@
##             master   #23337      +/-   ##
============================================
+ Coverage     73.57%   74.53%   +0.95%     
- Complexity    32624    33923    +1299     
============================================
  Files          1877     1934      +57     
  Lines        139502   144980    +5478     
  Branches      15299    15838     +539     
============================================
+ Hits         102638   108056    +5418     
+ Misses        28908    28648     -260     
- Partials       7956     8276     +320     
Flag Coverage Δ
inttests 27.49% <ø> (+2.90%) ⬆️
systests 24.58% <ø> (+0.25%) ⬆️
unittests 73.89% <ø> (+1.04%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

see 600 files with indirect coverage changes

@lhotari lhotari merged commit 7d4ac9d into apache:master Sep 23, 2024
52 of 55 checks passed
lhotari added a commit that referenced this pull request Sep 23, 2024
lhotari added a commit that referenced this pull request Sep 23, 2024
nikhil-ctds pushed a commit to datastax/pulsar that referenced this pull request Sep 26, 2024
…ge tagging (apache#23337)

(cherry picked from commit 7d4ac9d)
(cherry picked from commit 0b589b4)
srinath-ctds pushed a commit to datastax/pulsar that referenced this pull request Sep 26, 2024
…ge tagging (apache#23337)

(cherry picked from commit 7d4ac9d)
(cherry picked from commit 0b589b4)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants