@@ -57,8 +57,19 @@ COPY --chown=stackable:stackable trino/stackable/patches/${PRODUCT} /stackable/t
57
57
# hadolint ignore=SC2215
58
58
RUN --mount=type=cache,target=/root/.m2/repository cd "trino-server-${PRODUCT}-src" && \
59
59
./patches/apply_patches.sh ${PRODUCT} && \
60
+ # Trino is using something (git-commit-id-plugin in the past, maybe something else now) that is
61
+ # reading the Git history and searches for a tag to pull the version from. It sounds weird to me
62
+ # why someone would do that over just picking the version from the pom.xml, but they propably
63
+ # have their reasons. See e.g. https://github.com/trinodb/trino/discussions/18963.
64
+ # So we fake it till we make it and create a Git repo and the correct tag. The trino-operator
65
+ # smoke test checks that "select version()" is working.
66
+ git init && \
67
+ git config user.email "fake.commiter@stackable.tech" && \
68
+ git config user.name "Fake commiter" && \
69
+ git commit --allow-empty --message "Fake commit, so that we can create a tag" && \
70
+ git tag ${PRODUCT} && \
60
71
# We need to use ./mvnw instead of mvn to get a recent maven version (which is required to build Trino)
61
- ./mvnw package -DskipTests -Dmaven.gitcommitid.skip=true - -projects="!docs,!core/trino-server-rpm" && \
72
+ ./mvnw package -DskipTests --projects="!docs,!core/trino-server-rpm" && \
62
73
# Delete the worst intermediate build products to free some space
63
74
rm -r /stackable/trino-server-${PRODUCT}-src/plugin/*/target /stackable/trino-server-${PRODUCT}-src/core/trino-server/target/trino-server-${PRODUCT} && \
64
75
# Extract from tarball to save space; the tarball deduplicates jars (replacing them with symlinks),
0 commit comments