Dockerfile 1.1 KB

123456789101112131415161718192021222324252627282930
  1. FROM ubuntu
  2. RUN sed -i 's/deb.debian.org/mirrors.tuna.tsinghua.edu.cn/g' /etc/apt/sources.list \
  3. && sed -i 's/security.debian.org/mirrors.tuna.tsinghua.edu.cn/g' /etc/apt/sources.list
  4. RUN set -xe && apt-get update
  5. RUN apt-get -y install python3-pip zsh
  6. # 安装miniconda
  7. ENV PYTHON_VERSION 3
  8. RUN chsh -s `which zsh`
  9. RUN apt install -y curl
  10. RUN curl -o ~/miniconda.sh -O https://repo.anaconda.com/miniconda/Miniconda${PYTHON_VERSION}-latest-Linux-x86_64.sh && \
  11. chmod +x ~/miniconda.sh && \
  12. ~/miniconda.sh -b -p /opt/conda && \
  13. rm ~/miniconda.sh
  14. RUN ln /opt/conda/bin/conda /usr/local/bin/conda
  15. RUN conda init zsh
  16. RUN conda install mamba -n base -c conda-forge
  17. RUN ln /opt/conda/bin/mamba /usr/local/bin/mamba && mamba init zsh
  18. ADD environment.yml /environment.yml
  19. ADD main.py /main.py
  20. ADD utils.py /utils.py
  21. ADD datax.py /datax.py
  22. ADD user.keytab /user.keytab
  23. ADD krb5.conf /krb5.conf
  24. RUN cp krb5.conf /etc
  25. RUN apt-get install -y iputils-ping
  26. RUN conda env create -f /environment.yml && rm -rf /root/.cache
  27. # RUN python3 -m venv venv
  28. RUN apt-get install -y vim