1
0
mirror of https://gitee.com/sui-feng-cb/AzurLaneAutoScript1 synced 2026-03-09 18:39:04 +08:00
AzurLaneAutoScript/deploy/docker/Dockerfile

24 lines
814 B
Docker
Raw Normal View History

FROM condaforge/mambaforge:4.12.0-0
2021-11-26 18:59:00 +08:00
# Set remote and local dirs
2021-11-30 01:12:03 +08:00
WORKDIR /app
ENV SOURCE=./
2021-11-26 18:59:00 +08:00
# Install the base conda environment
2021-11-30 01:12:03 +08:00
ENV PYROOT=/app/pyroot
RUN mamba create --prefix $PYROOT python==3.7.6 -y
2021-11-26 18:59:00 +08:00
RUN apt update
RUN apt install -y adb netcat
2021-11-26 18:59:00 +08:00
# Install the requriements to the conda environment
2022-06-21 06:02:06 +08:00
COPY $SOURCE/requirements.txt /app/requirements-docker.txt
RUN $PYROOT/bin/pip install -r /app/requirements-docker.txt
2021-11-26 18:59:00 +08:00
# Initial download of UIAutomator2 is really slow with appetizer mirror
RUN sed -i "s#path = mirror_download(url,#path = cache_download(url,#" $PYROOT/lib/python3.7/site-packages/uiautomator2/init.py
2021-11-28 21:15:57 +08:00
# When running the image, mount the ALAS folder into the container
RUN git config --global --add safe.directory /app/AzurLaneAutoScript
2021-11-30 01:12:03 +08:00
CMD $PYROOT/bin/python /app/AzurLaneAutoScript/gui.py