dm/docker/base-dm/Dockerfile

24 lines
888 B
Docker

# base-dm
FROM base
# 添加用户
RUN useradd -m -s /bin/bash dmdba \
# 修改用户密码
&& echo "dmdba:123456" | chpasswd \
&& apt-get -y update \
&& apt-get install -y --no-install-recommends \
p7zip-full unzip wget \
&& apt-get clean \
&& rm -rf /config/* /tmp/* /var/lib/apt/lists/* /var/tmp/*
WORKDIR /home/dmdba
# 下载安装包并解压
RUN wget https://download.dameng.com/eco/adapter/DM8/202405/dm8_20240408_x86_rh7_64_ent_8.1.3.140.zip --no-check-certificate \
&& unzip dm8_20240408_x86_rh7_64_ent_8.1.3.140.zip \
&& chown -R dmdba:dmdba /home/dmdba \
&& rm -f dm8_20240408_x86_rh7_64_ent_8.1.3.140.zip \
&& 7z x dm8_20240408_x86_rh7_64.iso \
&& rm -f dm8_20240408_x86_rh7_64.iso \
&& chmod +x DMInstall.bin \
&& apt-get remove -y p7zip-full unzip wget
USER dmdba
CMD ["/bin/bash", "-e"]