Ensure Docker APT is not used

Error: Docker APT is used

Bridgecrew Policy ID: BC_DOCKER_NETWORKING_1
Checkov Check ID: CKV_DOCKER_9
Severity: LOW

Docker APT is used

Description

It is generally a best practice to avoid using APT (Advanced Package Tool) when working with Docker containers. This is because APT is designed to work with traditional server-based environments, and may not be well-suited for use with containers.

Using APT with Docker containers can create potential security risks, as it may allow packages to be installed that are not designed to work with containers. This can lead to compatibility issues and potentially compromise the security of your containers.

Fix - Buildtime

Docker

FROM busybox:1.0
RUN apt-get install curl
HEALTHCHECK CMD curl --fail http://localhost:3000 || exit 1