Refactoring and set docker from debian
All checks were successful
release / release-default (push) Successful in 1h14m7s

This commit is contained in:
Astound 2025-07-21 11:16:43 -05:00
parent 5e4f5331a3
commit 1bb18030df
Signed by: kaiser
GPG Key ID: 97504AF0027B1A56

View File

@ -24,56 +24,30 @@ ENV DOCKER_USER=coder \
PASSWORD=undefined \ PASSWORD=undefined \
HASHED_PASSWORD=undefined HASHED_PASSWORD=undefined
# Base packages # Base packages + Trivy + Docker
RUN apt-get update -y && apt-get upgrade -y && apt-get install --no-install-recommends -y \ RUN set -eux; \
bash \ apt-get update && \
bash-completion \ apt-get upgrade -y && \
ca-certificates \ apt-get install --no-install-recommends -y \
curl \ bash bash-completion ca-certificates curl dbus default-jre doas dos2unix dumb-init file \
dbus \ fuse3 git gnupg iproute2 iptables jq lsb-release lsof make nano net-tools nodejs npm \
default-jre \ openssh-client passwd patch pipx python3 python3-pip python3-venv shellcheck siege \
doas \ sudo tar tree uidmap unzip virtualenv wget xz-utils; \
dos2unix \ \
dumb-init \ # Trivy
file \ curl -fsSL https://aquasecurity.github.io/trivy-repo/deb/public.key | gpg --dearmor > /usr/share/keyrings/trivy.gpg && \
fuse3 \ echo "deb [signed-by=/usr/share/keyrings/trivy.gpg] https://aquasecurity.github.io/trivy-repo/deb generic main" > /etc/apt/sources.list.d/trivy.list && \
git \ apt-get update && apt-get install --no-install-recommends -y trivy; \
gnupg \ \
iproute2 \ # Docker
iptables \ install -m 0755 -d /etc/apt/keyrings && \
jq \ curl -fsSL https://download.docker.com/linux/debian/gpg -o /etc/apt/keyrings/docker.asc && \
lsb-release \ chmod a+r /etc/apt/keyrings/docker.asc && \
lsof \ echo "deb [arch=$(dpkg --print-architecture) signed-by=/etc/apt/keyrings/docker.asc] https://download.docker.com/linux/debian bookworm stable" > /etc/apt/sources.list.d/docker.list && \
make \ apt-get update && \
nano \ apt-get install --no-install-recommends -y docker-ce docker-ce-cli containerd.io docker-buildx-plugin docker-compose-plugin; \
net-tools \ \
nodejs \ apt-get clean && rm -rf /var/lib/apt/lists/*
npm \
openssh-client \
passwd \
patch \
pipx \
python3 \
python3-pip \
python3-venv \
shellcheck \
siege \
sudo \
tar \
tree \
uidmap \
unzip \
virtualenv \
wget \
xz-utils && \
curl -fsSL https://aquasecurity.github.io/trivy-repo/deb/public.key | \
gpg --dearmor > /usr/share/keyrings/trivy.gpg && \
echo "deb [signed-by=/usr/share/keyrings/trivy.gpg] https://aquasecurity.github.io/trivy-repo/deb generic main" > /etc/apt/sources.list.d/trivy.list && \
apt-get update -y && apt-get install --no-install-recommends -y trivy && \
apt-get clean && rm -rf /var/lib/apt/lists/*
# Docker
RUN curl -fsSL https://get.docker.com | sh && dockerd --version
# AWS CLI (handle arch manually) # AWS CLI (handle arch manually)
RUN set -e; \ RUN set -e; \