Commit a8e4255d authored by nanahira's avatar nanahira

fix

parent f969b6aa
Pipeline #4794 canceled with stages
in 1 minute and 23 seconds
...@@ -18,77 +18,71 @@ variables: ...@@ -18,77 +18,71 @@ variables:
build_lite_x86: build_lite_x86:
stage: build stage: build
tags: tags:
- docker - docker
variables:
TARGET_IMAGE: $CONTAINER_TEST_IMAGE_X86_LITE
script: script:
- TARGET_IMAGE=$CONTAINER_TEST_IMAGE_X86_LITE
- docker login -u $CI_REGISTRY_USER -p $CI_REGISTRY_PASSWORD $CI_REGISTRY - docker login -u $CI_REGISTRY_USER -p $CI_REGISTRY_PASSWORD $CI_REGISTRY
- docker build --pull --no-cache -f ./Dockerfile.lite -t $TARGET_IMAGE . - docker build --pull --no-cache -f ./Dockerfile.lite -t $TARGET_IMAGE .
- docker push $TARGET_IMAGE - docker push $TARGET_IMAGE
build_lite_arm: build_lite_arm:
stage: build stage: build
tags: tags:
- docker-arm - docker-arm
variables:
TARGET_IMAGE: $CONTAINER_TEST_IMAGE_ARM_LITE
script: script:
- TARGET_IMAGE=$CONTAINER_TEST_IMAGE_ARM_LITE
- docker login -u $CI_REGISTRY_USER -p $CI_REGISTRY_PASSWORD $CI_REGISTRY - docker login -u $CI_REGISTRY_USER -p $CI_REGISTRY_PASSWORD $CI_REGISTRY
- docker build --pull --no-cache -f ./Dockerfile.lite -t $TARGET_IMAGE . - docker build --pull --no-cache -f ./Dockerfile.lite -t $TARGET_IMAGE .
- docker push $TARGET_IMAGE - docker push $TARGET_IMAGE
build_full_x86: build_full_x86:
stage: build2 stage: build2
tags: tags:
- docker - docker
variables:
SOURCE_IMAGE: $CONTAINER_TEST_IMAGE_X86_LITE
TARGET_IMAGE: $CONTAINER_TEST_IMAGE_X86_FULL
script: script:
- TARGET_IMAGE=$CONTAINER_TEST_IMAGE_X86_FULL
- SOURCE_IMAGE=$CONTAINER_TEST_IMAGE_X86_LITE
- docker login -u $CI_REGISTRY_USER -p $CI_REGISTRY_PASSWORD $CI_REGISTRY - docker login -u $CI_REGISTRY_USER -p $CI_REGISTRY_PASSWORD $CI_REGISTRY
- docker build --build-arg BASE_IMAGE=$SOURCE_IMAGE --pull --no-cache -t $TARGET_IMAGE . - docker build --build-arg BASE_IMAGE=$SOURCE_IMAGE --pull --no-cache -t
$TARGET_IMAGE .
- docker push $TARGET_IMAGE - docker push $TARGET_IMAGE
build_full_arm: build_full_arm:
stage: build2 stage: build2
tags: tags:
- docker-arm - docker-arm
variables:
SOURCE_IMAGE: $CONTAINER_TEST_IMAGE_ARM_LITE
TARGET_IMAGE: $CONTAINER_TEST_IMAGE_ARM_FULL
script: script:
- TARGET_IMAGE=$CONTAINER_TEST_IMAGE_ARM_FULL
- SOURCE_IMAGE=$CONTAINER_TEST_IMAGE_ARM_LITE
- docker login -u $CI_REGISTRY_USER -p $CI_REGISTRY_PASSWORD $CI_REGISTRY - docker login -u $CI_REGISTRY_USER -p $CI_REGISTRY_PASSWORD $CI_REGISTRY
- docker build --build-arg BASE_IMAGE=$SOURCE_IMAGE --pull --no-cache -t $TARGET_IMAGE . - docker build --build-arg BASE_IMAGE=$SOURCE_IMAGE --pull --no-cache -t
$TARGET_IMAGE .
- docker push $TARGET_IMAGE - docker push $TARGET_IMAGE
combine_lite: combine_lite:
stage: build2 stage: build2
tags: tags:
- docker - docker
variables:
SOURCE_IMAGE_1: $CONTAINER_TEST_IMAGE_X86_LITE
SOURCE_IMAGE_2: $CONTAINER_TEST_IMAGE_ARM_LITE
TARGET_IMAGE: $CONTAINER_TEST_IMAGE_LITE
script: script:
- TARGET_IMAGE=$CONTAINER_TEST_IMAGE_LITE
- SOURCE_IMAGE_2=$CONTAINER_TEST_IMAGE_ARM_LITE
- SOURCE_IMAGE_1=$CONTAINER_TEST_IMAGE_X86_LITE
- docker pull $SOURCE_IMAGE_1 - docker pull $SOURCE_IMAGE_1
- docker pull $SOURCE_IMAGE_2 - docker pull $SOURCE_IMAGE_2
- docker manifest create $TARGET_IMAGE --amend $SOURCE_IMAGE_1 --amend $SOURCE_IMAGE_2 - docker manifest create $TARGET_IMAGE --amend $SOURCE_IMAGE_1 --amend
$SOURCE_IMAGE_2
- docker manifest push $TARGET_IMAGE - docker manifest push $TARGET_IMAGE
combine_full: combine_full:
stage: combine stage: combine
tags: tags:
- docker - docker
variables:
SOURCE_IMAGE_1: $CONTAINER_TEST_IMAGE_X86_FULL
SOURCE_IMAGE_2: $CONTAINER_TEST_IMAGE_ARM_FULL
TARGET_IMAGE: $CONTAINER_TEST_IMAGE_FULL
script: script:
- TARGET_IMAGE=$CONTAINER_TEST_IMAGE_FULL
- SOURCE_IMAGE_2=$CONTAINER_TEST_IMAGE_ARM_FULL
- SOURCE_IMAGE_1=$CONTAINER_TEST_IMAGE_X86_FULL
- docker pull $SOURCE_IMAGE_1 - docker pull $SOURCE_IMAGE_1
- docker pull $SOURCE_IMAGE_2 - docker pull $SOURCE_IMAGE_2
- docker manifest create $TARGET_IMAGE --amend $SOURCE_IMAGE_1 --amend $SOURCE_IMAGE_2 - docker manifest create $TARGET_IMAGE --amend $SOURCE_IMAGE_1 --amend
$SOURCE_IMAGE_2
- docker manifest push $TARGET_IMAGE - docker manifest push $TARGET_IMAGE
upload_stuff_to_minio: upload_stuff_to_minio:
...@@ -102,19 +96,19 @@ upload_stuff_to_minio: ...@@ -102,19 +96,19 @@ upload_stuff_to_minio:
- cd /ygopro-server - cd /ygopro-server
- mkdir /dist - mkdir /dist
- tar zcfv /dist/ygopro-server.tar.gz ./* - tar zcfv /dist/ygopro-server.tar.gz ./*
- aws s3 --endpoint=https://minio.mycard.moe:9000 cp /dist/ygopro-server.tar.gz s3://mycard/srvpro/ygopro-server.tar.gz - aws s3 --endpoint=https://minio.mycard.moe:9000 cp
/dist/ygopro-server.tar.gz s3://mycard/srvpro/ygopro-server.tar.gz
only: only:
- master - master
deploy_latest_full: deploy_latest_full:
stage: deploy stage: deploy
tags: tags:
- docker - docker
variables:
SOURCE_IMAGE: $CONTAINER_TEST_IMAGE_FULL
TARGET_IMAGE: $CONTAINER_RELEASE_IMAGE_FULL
TARGET_IMAGE_2: $CONTAINER_RELEASE_IMAGE
script: script:
- TARGET_IMAGE_2=$CONTAINER_RELEASE_IMAGE
- TARGET_IMAGE=$CONTAINER_RELEASE_IMAGE_FULL
- SOURCE_IMAGE=$CONTAINER_TEST_IMAGE_FULL
- docker pull $SOURCE_IMAGE - docker pull $SOURCE_IMAGE
- docker tag $SOURCE_IMAGE $TARGET_IMAGE - docker tag $SOURCE_IMAGE $TARGET_IMAGE
- docker push $TARGET_IMAGE - docker push $TARGET_IMAGE
...@@ -122,30 +116,26 @@ deploy_latest_full: ...@@ -122,30 +116,26 @@ deploy_latest_full:
- docker push $TARGET_IMAGE_2 - docker push $TARGET_IMAGE_2
only: only:
- master - master
deploy_latest_lite: deploy_latest_lite:
stage: deploy stage: deploy
tags: tags:
- docker - docker
variables:
SOURCE_IMAGE: $CONTAINER_TEST_IMAGE_LITE
TARGET_IMAGE: $CONTAINER_RELEASE_IMAGE_LITE
script: script:
- TARGET_IMAGE=$CONTAINER_RELEASE_IMAGE_LITE
- SOURCE_IMAGE=$CONTAINER_TEST_IMAGE_LITE
- docker pull $SOURCE_IMAGE - docker pull $SOURCE_IMAGE
- docker tag $SOURCE_IMAGE $TARGET_IMAGE - docker tag $SOURCE_IMAGE $TARGET_IMAGE
- docker push $TARGET_IMAGE - docker push $TARGET_IMAGE
only: only:
- master - master
deploy_tag_full: deploy_tag_full:
stage: deploy stage: deploy
tags: tags:
- docker - docker
variables:
SOURCE_IMAGE: $CONTAINER_TEST_IMAGE_FULL
TARGET_IMAGE: $CI_REGISTRY_IMAGE:$CI_COMMIT_TAG-full
TARGET_IMAGE_2: $CI_REGISTRY_IMAGE:$CI_COMMIT_TAG
script: script:
- TARGET_IMAGE_2=$CI_REGISTRY_IMAGE:$CI_COMMIT_TAG
- TARGET_IMAGE=$CI_REGISTRY_IMAGE:$CI_COMMIT_TAG-full
- SOURCE_IMAGE=$CONTAINER_TEST_IMAGE_FULL
- docker pull $SOURCE_IMAGE - docker pull $SOURCE_IMAGE
- docker tag $SOURCE_IMAGE $TARGET_IMAGE - docker tag $SOURCE_IMAGE $TARGET_IMAGE
- docker push $TARGET_IMAGE - docker push $TARGET_IMAGE
...@@ -153,15 +143,13 @@ deploy_tag_full: ...@@ -153,15 +143,13 @@ deploy_tag_full:
- docker push $TARGET_IMAGE_2 - docker push $TARGET_IMAGE_2
only: only:
- tags - tags
deploy_tag_lite: deploy_tag_lite:
stage: deploy stage: deploy
tags: tags:
- docker - docker
variables:
SOURCE_IMAGE: $CONTAINER_TEST_IMAGE_LITE
TARGET_IMAGE: $CI_REGISTRY_IMAGE:$CI_COMMIT_TAG-lite
script: script:
- TARGET_IMAGE=$CI_REGISTRY_IMAGE:$CI_COMMIT_TAG-lite
- SOURCE_IMAGE=$CONTAINER_TEST_IMAGE_LITE
- docker pull $SOURCE_IMAGE - docker pull $SOURCE_IMAGE
- docker tag $SOURCE_IMAGE $TARGET_IMAGE - docker tag $SOURCE_IMAGE $TARGET_IMAGE
- docker push $TARGET_IMAGE - docker push $TARGET_IMAGE
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment