diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index ce4d779..4727288 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -6,12 +6,14 @@ services: stages: - build_amd64 - build_arm64 + - build_cuda before_script: - docker -v build_amd64: stage: build_amd64 + needs: [] before_script: - git submodule update --init --recursive script: @@ -22,11 +24,23 @@ build_amd64: build_arm64: stage: build_arm64 + needs: [] before_script: - git submodule update --init --recursive - docker run --rm --privileged multiarch/qemu-user-static --reset -p yes script: - docker login -u $CI_REGISTRY_USER -p $CI_REGISTRY_PASSWORD $CI_REGISTRY - - docker buildx build --platform arm64 --build-arg "with_models=true" -t libretranslate-arm64 ./LibreTranslate - - docker tag libretranslate-arm64 $CI_REGISTRY/manalejandro/libretranslate-api/libretranslate-api-arm64:latest - - docker push $CI_REGISTRY/manalejandro/libretranslate-api/libretranslate-api-arm64:latest + - docker buildx build --platform arm64 --build-arg "with_models=true" -t libretranslate:arm64 -f LibreTranslate/docker/arm.Dockerfile LibreTranslate/ + - docker tag libretranslate:arm64 $CI_REGISTRY/manalejandro/libretranslate-api/libretranslate-api:arm64 + - docker push $CI_REGISTRY/manalejandro/libretranslate-api/libretranslate-api:arm64 + +build_cuda: + stage: build_cuda + needs: [] + before_script: + - git submodule update --init --recursive + script: + - docker login -u $CI_REGISTRY_USER -p $CI_REGISTRY_PASSWORD $CI_REGISTRY + - docker buildx build --build-arg "with_models=true" -t libretranslate:cuda -f LibreTranslate/docker/cuda.Dockerfile LibreTranslate/ + - docker tag libretranslate:cuda $CI_REGISTRY/manalejandro/libretranslate-api/libretranslate-api:cuda + - docker push $CI_REGISTRY/manalejandro/libretranslate-api/libretranslate-api:cuda