mirror of
https://hubproxy.babadafafafafa.cn/https://github.com/boypt/openssh-rpms.git
synced 2026-09-20 08:03:38 +08:00
33 lines
1.1 KiB
Docker
33 lines
1.1 KiB
Docker
# Official: https://hub.docker.com/_/rockylinux
|
|
ARG VERSION_NUM="9"
|
|
FROM rockylinux:$VERSION_NUM
|
|
ARG VERSION_NUM
|
|
ARG MIRROR=0
|
|
LABEL Author="Rex Zhou <zrx879582094@gmail.com>"
|
|
|
|
WORKDIR /data
|
|
|
|
# Copy all files
|
|
COPY . /data
|
|
|
|
# Official webpage: https://developer.aliyun.com/mirror/rockylinux
|
|
RUN if [ "$MIRROR" != "0" ]; then \
|
|
MIRROR_URL="https://mirrors.aliyun.com/rockylinux" && \
|
|
sed -e 's|^mirrorlist=|#mirrorlist=|g' \
|
|
-e "s|^#baseurl=http://dl.rockylinux.org/\$contentdir|baseurl=$MIRROR_URL|g" \
|
|
-i.bak \
|
|
/etc/yum.repos.d/*.repo; \
|
|
else \
|
|
MIRROR_URL="https://mirrors.ocf.berkeley.edu/rocky" && \
|
|
sed -e 's|^mirrorlist=|#mirrorlist=|g' \
|
|
-e "s|^#baseurl=http://dl.rockylinux.org/\$contentdir|baseurl=$MIRROR_URL|g" \
|
|
-i.bak \
|
|
/etc/yum.repos.d/*.repo; \
|
|
fi && \
|
|
rm -rf /var/cache/yum/ && \
|
|
yum clean all && yum makecache timer && \
|
|
yum install -y wget autoconf automake gcc perl make rpm-build pam-devel krb5-devel zlib-devel libXt-devel libX11-devel gtk2-devel systemd-devel openssl-devel && \
|
|
yum clean all
|
|
|
|
CMD ["./docker/docker_compile.sh"]
|