Skip to content
Merged
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
9 changes: 2 additions & 7 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
#checkov:skip=CKV_DOCKER_2
#checkov:skip=CKV_DOCKER_3
#trivy:ignore:AVD-DS-0002
Copy link

Copilot AI Sep 25, 2025

Choose a reason for hiding this comment

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

The trivy ignore directive lacks a comment explaining why this security warning is being suppressed. Consider adding a comment like # Required: Running as root needed for GitHub Actions output permissions

Suggested change
#trivy:ignore:AVD-DS-0002
#trivy:ignore:AVD-DS-0002 # Required: Running as root needed for GitHub Actions output permissions

Copilot uses AI. Check for mistakes.
FROM python:3.13.7-slim@sha256:58c30f5bfaa718b5803a53393190b9c68bd517c44c6c94c1b6c8c172bcfad040
LABEL org.opencontainers.image.source https://github.com/github/evergreen

Check warning on line 5 in Dockerfile

View workflow job for this annotation

GitHub Actions / release_image / create_action_images

Legacy key/value format with whitespace separator should not be used

LegacyKeyValueFormat: "LABEL key=value" should be used instead of legacy "LABEL key value" format More info: https://docs.docker.com/go/dockerfile/rule/legacy-key-value-format/

WORKDIR /action/workspace
COPY requirements.txt *.py /action/workspace/
Expand All @@ -9,13 +10,7 @@
RUN python3 -m pip install --no-cache-dir -r requirements.txt \
&& apt-get -y update \
&& apt-get -y install --no-install-recommends git=1:2.47.3-0+deb13u1 \
&& rm -rf /var/lib/apt/lists/* \
&& addgroup --system appuser \
&& adduser --system --ingroup appuser --home /action/workspace --disabled-login appuser \
&& chown -R appuser:appuser /action/workspace

# Run the action as a non-root user
USER appuser
&& rm -rf /var/lib/apt/lists/*
Copy link

Copilot AI Sep 25, 2025

Choose a reason for hiding this comment

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

Running the container as root user increases the attack surface. Consider documenting in the README or inline comments the specific permission issues with $GITHUB_OUTPUT that prevent using a non-root user, and any mitigations in place.

Copilot uses AI. Check for mistakes.

# Add a simple healthcheck to satisfy container scanners
HEALTHCHECK --interval=30s --timeout=10s --start-period=10s --retries=3 \
Expand Down
Loading