Skip to content

Commit 74685a0

Browse files
committed
feat(nifi): Add nifi-iceberg-bundle
1 parent 54ce0e8 commit 74685a0

File tree

2 files changed

+42
-0
lines changed

2 files changed

+42
-0
lines changed

nifi/Dockerfile

Lines changed: 41 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -80,6 +80,46 @@ rm -rf /stackable/nifi-${PRODUCT}/docs
8080
chmod -R g=u /stackable
8181
EOF
8282

83+
FROM stackable/image/java-devel AS nifi-iceberg-bundle-builder
84+
85+
ARG NIFI_ICEBERG_BUNDLE
86+
ARG PRODUCT
87+
ARG STACKABLE_USER_UID
88+
89+
USER ${STACKABLE_USER_UID}
90+
WORKDIR /build
91+
92+
RUN <<EOF
93+
mkdir -p /stackable
94+
95+
if [[ "${PRODUCT}" != 1.* ]] ; then
96+
# curl "https://github.com/stackabletech/nifi-iceberg-bundle/archive/refs/tags/v${NIFI_ICEBERG_BUNDLE}.tar.gz" | tar -xzC .
97+
curl "https://github.com/stackabletech/nifi-iceberg-bundle/archive/refs/heads/main.tar.gz" | tar -xzC .
98+
# cd nifi-iceberg-bundle-${NIFI_ICEBERG_BUNDLE}
99+
cd nifi-iceberg-bundle-main
100+
101+
mvn \
102+
--batch-mode \
103+
--no-transfer-progress\
104+
clean package \
105+
-D nifi.version=${PRODUCT} \
106+
-Dmaven.javadoc.skip=true \
107+
-Denforcer.skip=true
108+
# We need "-Denforcer.skip=true", as the Maven version is too old
109+
110+
cp ./nifi-iceberg-services-api-nar/target/nifi-iceberg-services-api-nar-${NIFI_ICEBERG_BUNDLE}.nar /stackable
111+
cp ./nifi-iceberg-services-nar/target/nifi-iceberg-services-nar-${NIFI_ICEBERG_BUNDLE}.nar /stackable
112+
cp ./nifi-iceberg-processors-nar/target/nifi-iceberg-processors-nar-${NIFI_ICEBERG_BUNDLE}.nar /stackable
113+
114+
cd ..
115+
# Save disk space, even for intermediate images
116+
rm -rf nifi-iceberg-bundle-main
117+
118+
# Set correct groups
119+
chmod g=u /stackable/*.nar
120+
fi
121+
EOF
122+
83123
FROM stackable/image/java-base AS final
84124

85125
ARG PRODUCT
@@ -96,6 +136,7 @@ LABEL name="Apache NiFi" \
96136

97137
COPY --chown=${STACKABLE_USER_UID}:0 --from=nifi-builder /stackable/nifi-${PRODUCT} /stackable/nifi-${PRODUCT}/
98138
COPY --chown=${STACKABLE_USER_UID}:0 --from=nifi-builder /stackable/stackable-bcrypt.jar /stackable/stackable-bcrypt.jar
139+
COPY --chown=${STACKABLE_USER_UID}:0 --from=nifi-iceberg-bundle-builder /stackable/*.nar /stackable/nifi-${PRODUCT}/lib/
99140

100141
COPY --chown=${STACKABLE_USER_UID}:0 nifi/stackable/bin /stackable/bin
101142
COPY --chown=${STACKABLE_USER_UID}:0 nifi/licenses /licenses

nifi/versions.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,5 +13,6 @@
1313
"product": "2.2.0",
1414
"java-base": "21",
1515
"java-devel": "21",
16+
"nifi_iceberg_bundle": "0.0.1",
1617
},
1718
]

0 commit comments

Comments
 (0)