Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
20 changes: 20 additions & 0 deletions .buildkite/pipeline.yml
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
---
IMAGE_NAME: &IMAGE_NAME invocaops/prometheus

steps:
- label: ":docker: Image Build & Push"
timeout_in_minutes: 30
env:
IMAGE_NAME: *IMAGE_NAME
agents:
queue: buildkit-daemonless
buildkit: true
daemonless: true
command: >
buildctl-daemonless build
--output type=image,"name=$IMAGE_NAME:$BUILDKITE_COMMIT,$IMAGE_NAME:$BUILDKITE_BRANCH_DOCKER_SAFE",push=true
--progress plain
--frontend dockerfile.v0
--opt filename=Dockerfile.invoca
--local context=.
--local dockerfile=.
22 changes: 22 additions & 0 deletions Dockerfile.invoca
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,22 @@
FROM golang:1.26 AS compile
RUN curl -fsSL https://deb.nodesource.com/setup_lts.x | bash - \
&& apt-get install -yq nodejs build-essential
Comment on lines +2 to +3
WORKDIR /build
COPY . .
RUN make build

FROM quay.io/prometheus/busybox-linux-amd64:latest

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Medium IaC Finding

Image Version Using 'latest'
on resource FROM quay.io/prometheus/busybox-linux-amd64:latest

More Details
When building images, always tag them with useful tags which codify version information, intended destination (prod or test, for instance), stability, or other information that is useful when deploying the application in different environments. Do not rely on the automatically-created latest tag

Expected

FROM quay.io/prometheus/busybox-linux-amd64:latest should use a specific version instead of 'latest'

Found

FROM quay.io/prometheus/busybox-linux-amd64:latest uses the 'latest' tag

Rule ID: 91ba29eb-0fe8-4885-9fd8-7f3667a8b689


To ignore this finding as an exception, reply to this conversation with #wiz_ignore reason

If you'd like to ignore this finding in all future scans, add an exception in the .wiz file (learn more) or create an Ignore Rule (learn more).


To get more details on how to remediate this issue using AI, reply to this conversation with #wiz remediate

COPY --from=compile /build/prometheus /bin/prometheus
COPY --from=compile /build/promtool /bin/promtool
COPY --from=compile /build/documentation/examples/prometheus.yml /etc/prometheus/prometheus.yml
COPY --from=compile /build/consoles/ /usr/share/prometheus/consoles/
COPY --from=compile /build/console_libraries/ /usr/share/prometheus/console_libraries/
WORKDIR /prometheus
RUN ln -s /usr/share/prometheus/console_libraries /usr/share/prometheus/consoles/ /etc/prometheus/ && \
chown -R nobody:nobody /etc/prometheus /prometheus
USER nobody
EXPOSE 9090
VOLUME [ "/prometheus" ]
ENTRYPOINT [ "/bin/prometheus" ]
CMD [ "--config.file=/etc/prometheus/prometheus.yml", \
"--storage.tsdb.path=/prometheus" ]
Loading