mirror of
https://github.com/aramperes/onetun.git
synced 2025-09-08 07:18:32 -04:00
Optimize apt-get commands to reduce image size in Dockerfile
This commit improves the Dockerfile by consolidating apt-get update and apt-get install commands into a single RUN statement and adding cleanup steps for the apt cache.
This commit is contained in:
parent
56c950d159
commit
2b6d21572e
1 changed files with 3 additions and 2 deletions
|
@ -15,8 +15,9 @@ COPY . .
|
|||
RUN cargo build --release
|
||||
|
||||
FROM debian:11-slim
|
||||
RUN apt-get update
|
||||
RUN apt-get install dumb-init -y
|
||||
RUN apt-get update \
|
||||
&& apt-get install dumb-init -y \
|
||||
&& rm -rf /var/lib/apt/lists/*
|
||||
|
||||
COPY --from=cargo-build /usr/src/onetun/target/release/onetun /usr/local/bin/onetun
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue