Skip to content

Commit

Permalink
update scripts
Browse files Browse the repository at this point in the history
  • Loading branch information
KumaTea committed Mar 30, 2021
1 parent 863c445 commit b2f8086
Show file tree
Hide file tree
Showing 6 changed files with 30 additions and 7 deletions.
23 changes: 23 additions & 0 deletions build.bat
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
cd docker
REM docker buildx build --pull --load --platform linux/arm/v7 -t kumatea/ext:py39 -f py39/Dockerfile .
REM docker buildx build --pull --load --platform linux/arm/v7 -t kumatea/ext:py38 -f py38/Dockerfile .
REM docker buildx build --pull --load --platform linux/arm/v7 -t kumatea/ext:py37 -f py37/Dockerfile .
REM docker buildx build --pull --load --platform linux/arm/v7 -t kumatea/ext:py36 -f py36/Dockerfile .

REM docker image prune

docker run -it --name py39e kumatea/ext:py39 bash /root/build-wheels.sh
docker cp py39e:/root/whl .
docker rm py39e

docker run -it --name py38e kumatea/ext:py38 bash /root/build-wheels.sh
docker cp py38e:/root/whl .
docker rm py38e

docker run -it --name py37e kumatea/ext:py37 bash /root/build-wheels.sh
docker cp py37e:/root/whl .
docker rm py37e

docker run -it --name py36e kumatea/ext:py36 bash /root/build-wheels.sh
docker cp py36e:/root/whl .
docker rm py36e
6 changes: 3 additions & 3 deletions docker/build-wheels.sh
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,8 @@

set -ex

# pip config set global.index-url https://mirrors.matrix.moe/pypi/web/simple
pip install -U -r /root/packages-stdln.txt -f https://ext.maku.ml/wheels.html -f https://torch.maku.ml/whl/stable.html
pip install -U -r /root/packages-deps.txt -f https://ext.maku.ml/wheels.html -f https://torch.maku.ml/whl/stable.html
# pip config set global.index-url https://mirrors.vmatrix.org.cn/pypi/web/simple
pip install -U -v -r /root/packages-stdln.txt -f https://ext.maku.ml/wheels.html -f https://torch.maku.ml/whl/stable.html
pip install -U -v -r /root/packages-deps.txt -f https://ext.maku.ml/wheels.html -f https://torch.maku.ml/whl/stable.html
mkdir /root/whl
cp -a $(find /root/.cache/pip | grep whl | tr '\n' ' ') /root/whl/ || echo "No new whl is built!"
2 changes: 1 addition & 1 deletion docker/py36/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ FROM python:3.6

RUN set -ex \
\
&& pip config set global.index-url https://mirrors.matrix.moe/pypi/web/simple \
&& pip config set global.index-url https://mirrors.vmatrix.org.cn/pypi/web/simple \
&& python3 -m pip install -U pip setuptools wheel \
&& rm -rf /root/.cache/*

Expand Down
2 changes: 1 addition & 1 deletion docker/py37/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ FROM python:3.7

RUN set -ex \
\
&& pip config set global.index-url https://mirrors.matrix.moe/pypi/web/simple \
&& pip config set global.index-url https://mirrors.vmatrix.org.cn/pypi/web/simple \
&& python3 -m pip install -U pip setuptools wheel \
&& rm -rf /root/.cache/*

Expand Down
2 changes: 1 addition & 1 deletion docker/py38/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ FROM python:3.8

RUN set -ex \
\
&& pip config set global.index-url https://mirrors.matrix.moe/pypi/web/simple \
&& pip config set global.index-url https://mirrors.vmatrix.org.cn/pypi/web/simple \
&& python3 -m pip install -U pip setuptools wheel \
&& rm -rf /root/.cache/*

Expand Down
2 changes: 1 addition & 1 deletion docker/py39/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ FROM python:3.9

RUN set -ex \
\
&& pip config set global.index-url https://mirrors.matrix.moe/pypi/web/simple \
&& pip config set global.index-url https://mirrors.vmatrix.org.cn/pypi/web/simple \
&& python3 -m pip install -U pip setuptools wheel \
&& rm -rf /root/.cache/*

Expand Down

0 comments on commit b2f8086

Please sign in to comment.