Fixes for Actions
All checks were successful
Build and push Docker image in git push / build (push) Successful in 4m58s
All checks were successful
Build and push Docker image in git push / build (push) Successful in 4m58s
This commit is contained in:
parent
fa36f93466
commit
fdbbbc3e3d
@ -17,8 +17,8 @@ fi;
|
|||||||
for platform in $PLATFORMS; do
|
for platform in $PLATFORMS; do
|
||||||
if [ "$platform" == "gpu" ]; then
|
if [ "$platform" == "gpu" ]; then
|
||||||
platform="amd64"
|
platform="amd64"
|
||||||
from_image="tmp_local/gpu_baseimage:amd64"
|
from_image="$IMAGE_REGISTRY/$IMAGE_OWNER/$IMAGE_NAME:tmp-local-only"
|
||||||
tag_image="$IMAGE_OWNER/$IMAGE_NAME:gpu-amd64"
|
tag_image="$IMAGE_REGISTRY/$IMAGE_OWNER/$IMAGE_NAME:gpu-amd64"
|
||||||
|
|
||||||
docker build \
|
docker build \
|
||||||
--pull \
|
--pull \
|
||||||
@ -28,7 +28,7 @@ for platform in $PLATFORMS; do
|
|||||||
"$SCRIPTPATH"
|
"$SCRIPTPATH"
|
||||||
else
|
else
|
||||||
from_image="$CPU_BASEIMAGE"
|
from_image="$CPU_BASEIMAGE"
|
||||||
tag_image="$IMAGE_OWNER/$IMAGE_NAME:cpu-$platform"
|
tag_image="$IMAGE_REGISTRY/$IMAGE_OWNER/$IMAGE_NAME:cpu-$platform"
|
||||||
|
|
||||||
docker pull --platform "linux/$platform" "$BASEIMAGE"
|
docker pull --platform "linux/$platform" "$BASEIMAGE"
|
||||||
fi;
|
fi;
|
||||||
|
@ -29,8 +29,16 @@ RUN apt-get update \
|
|||||||
curl wget \
|
curl wget \
|
||||||
htop screen
|
htop screen
|
||||||
|
|
||||||
RUN python3 -m pip install --no-cache-dir --break-system-packages \
|
# if cpu container (install cpu only versions; for gpu, gpu versions)
|
||||||
torch --index-url https://download.pytorch.org/whl/cpu
|
RUN if [ ! -d /usr/local/cuda/ ]; then \
|
||||||
|
python3 -m pip install --no-cache-dir --break-system-packages \
|
||||||
|
torch --index-url https://download.pytorch.org/whl/cpu; \
|
||||||
|
python3 -m pip install --no-cache-dir --break-system-packages \
|
||||||
|
faiss-cpu; \
|
||||||
|
else \
|
||||||
|
python3 -m pip install --no-cache-dir --break-system-packages \
|
||||||
|
faiss-gpu; \
|
||||||
|
fi;
|
||||||
|
|
||||||
RUN mkdir /ums-agenten/
|
RUN mkdir /ums-agenten/
|
||||||
|
|
||||||
|
@ -20,12 +20,12 @@ RUN apt update && \
|
|||||||
libopenmpi-dev && \
|
libopenmpi-dev && \
|
||||||
rm -rf /var/lib/apt/lists
|
rm -rf /var/lib/apt/lists
|
||||||
|
|
||||||
RUN python3 -m pip install --no-cache-dir \
|
RUN python3 -m pip install --no-cache-dir --break-system-packages \
|
||||||
torch --index-url https://download.pytorch.org/whl/cu124
|
torch --index-url https://download.pytorch.org/whl/cu124
|
||||||
|
|
||||||
RUN git clone https://github.com/NVIDIA/apex
|
RUN git clone https://github.com/NVIDIA/apex
|
||||||
RUN cd apex && \
|
RUN cd apex && \
|
||||||
pip install -v --disable-pip-version-check --no-cache-dir --no-build-isolation --config-settings "--build-option=--cpp_ext" --config-settings "--build-option=--cuda_ext" ./
|
pip install -v --disable-pip-version-check --no-cache-dir --no-build-isolation --break-system-packages --config-settings "--build-option=--cpp_ext" --config-settings "--build-option=--cuda_ext" ./
|
||||||
|
|
||||||
# fix library path for tensorflow and link a file
|
# fix library path for tensorflow and link a file
|
||||||
ENV LD_LIBRARY_PATH="${LD_LIBRARY_PATH}:/usr/local/cuda/lib64"
|
ENV LD_LIBRARY_PATH="${LD_LIBRARY_PATH}:/usr/local/cuda/lib64"
|
||||||
|
@ -17,7 +17,6 @@ matplotlib
|
|||||||
|
|
||||||
transformers
|
transformers
|
||||||
huggingface_hub
|
huggingface_hub
|
||||||
faiss-cpu
|
|
||||||
datasets
|
datasets
|
||||||
accelerate
|
accelerate
|
||||||
peft
|
peft
|
@ -7,7 +7,7 @@ source "$SCRIPTPATH/vars.sh"
|
|||||||
|
|
||||||
day_tag=$(date '+%Y-%m-%d')
|
day_tag=$(date '+%Y-%m-%d')
|
||||||
|
|
||||||
docker image ls "$IMAGE_OWNER/$IMAGE_NAME" --format '{{.Tag}}' | while read image_tag ;
|
docker image ls "$IMAGE_REGISTRY/$IMAGE_OWNER/$IMAGE_NAME" --format '{{.Tag}}' | while read image_tag ;
|
||||||
do
|
do
|
||||||
|
|
||||||
if [[ "$image_tag" =~ ^((gpu)|(cpu))-((arm64)|(amd64))$ ]];
|
if [[ "$image_tag" =~ ^((gpu)|(cpu))-((arm64)|(amd64))$ ]];
|
||||||
|
Loading…
x
Reference in New Issue
Block a user