Skip to content

Commit

Permalink
get image version and kafka connector version from build args
Browse files Browse the repository at this point in the history
  • Loading branch information
busma13 committed Feb 6, 2025
1 parent 1dd2dd5 commit dcbce40
Showing 1 changed file with 6 additions and 3 deletions.
9 changes: 6 additions & 3 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -1,8 +1,10 @@
ARG NODE_VERSION
ARG NODE_VERSION=22.13.1
FROM node:${NODE_VERSION}-alpine

ARG GITHUB_SHA
ARG BUILD_TIMESTAMP
ARG TERAFOUNDATION_KAFKA_CONNECTOR_VERSION
ARG IMAGE_VERSION

RUN apk --no-cache add \
bash \
Expand Down Expand Up @@ -55,7 +57,7 @@ RUN npm init --yes &> /dev/null \
--build \
--no-package-lock \
--no-optional \
'terafoundation_kafka_connector@~1.2.1' \
terafoundation_kafka_connector@~$TERAFOUNDATION_KAFKA_CONNECTOR_VERSION \
&& npm cache clean --force

RUN apk del .build-deps
Expand All @@ -77,8 +79,9 @@ LABEL org.opencontainers.image.created="$BUILD_TIMESTAMP" \
org.opencontainers.image.source="https://github.com/terascope/base-docker-image" \
org.opencontainers.image.title="Node-base" \
org.opencontainers.image.vendor="Terascope" \
org.opencontainers.image.version="$IMAGE_VERSION" \
io.terascope.image.node_version="$NODE_VERSION" \
io.terascope.image.kafka_connector_version="1.2.1"
io.terascope.image.kafka_connector_version="$TERAFOUNDATION_KAFKA_CONNECTOR_VERSION"

# Use tini to handle sigterm and zombie processes
ENTRYPOINT ["/sbin/tini", "--"]

0 comments on commit dcbce40

Please sign in to comment.