2
0
mirror of https://github.com/linka-cloud/d2vm.git synced 2024-11-25 17:16:25 +00:00

control packages by release version

Signed-off-by: LEI WANG <ssst0n3@gmail.com>
This commit is contained in:
LEI WANG 2024-08-29 17:37:01 +08:00
parent 0f86904ddc
commit b575dbc89e
No known key found for this signature in database

View File

@ -29,19 +29,22 @@ RUN ARCH="$([ "$(uname -m)" = "x86_64" ] && echo amd64 || echo arm64)"; \
iputils-ping && \ iputils-ping && \
find /boot -type l -exec rm {} \; find /boot -type l -exec rm {} \;
{{ if gt .Release.VersionID "14.04" }} {{ if ge .Release.VersionID "14.04" }}
RUN ARCH="$([ "$(uname -m)" = "x86_64" ] && echo amd64 || echo arm64)"; \ RUN ARCH="$([ "$(uname -m)" = "x86_64" ] && echo amd64 || echo arm64)"; \
apt-get update && \ apt-get update && \
DEBIAN_FRONTEND=noninteractive apt-get -y install --no-install-recommends \ DEBIAN_FRONTEND=noninteractive apt-get -y install --no-install-recommends \
iproute2 \ iproute2
{{ end }} {{ end }}
{{ if gt .Release.VersionID "16.04" }} {{ if ge .Release.VersionID "16.04" }}
RUN ARCH="$([ "$(uname -m)" = "x86_64" ] && echo amd64 || echo arm64)"; \ RUN ARCH="$([ "$(uname -m)" = "x86_64" ] && echo amd64 || echo arm64)"; \
apt-get update && \ apt-get update && \
DEBIAN_FRONTEND=noninteractive apt-get -y install --no-install-recommends \ DEBIAN_FRONTEND=noninteractive apt-get -y install --no-install-recommends \
systemd-sysv \ systemd-sysv \
systemd systemd
{{ end }}
{{ if gt .Release.VersionID "16.04" }}
RUN systemctl preset-all RUN systemctl preset-all
{{ end }} {{ end }}