...
 
Commits (2)
......@@ -18,9 +18,8 @@ pre_build:daemon:
- docker login -u "gitlab-ci-token" -p "$CI_JOB_TOKEN" $CI_REGISTRY
- docker pull $CI_REGISTRY_IMAGE:latest || true
- docker pull $CI_REGISTRY_IMAGE:$CI_COMMIT_REF_NAME || true
- docker build --cache-from $CI_REGISTRY_IMAGE:$CI_COMMIT_REF_NAME,$CI_REGISTRY_IMAGE:latest -t $CI_REGISTRY_IMAGE:ci-${CI_PIPELINE_ID} -t $CI_REGISTRY_IMAGE:$CI_COMMIT_REF_NAME .
- docker build --cache-from $CI_REGISTRY_IMAGE:$CI_COMMIT_REF_NAME,$CI_REGISTRY_IMAGE:latest -t $CI_REGISTRY_IMAGE:ci-${CI_PIPELINE_ID} .
- docker push $CI_REGISTRY_IMAGE:ci-${CI_PIPELINE_ID}
- docker push $CI_REGISTRY_IMAGE:${CI_COMMIT_REF_NAME}
pre_build:checker:
stage: pre_build_checks
......@@ -96,7 +95,7 @@ publish:docs:
publish:oci-image-layout:
stage: publish
tags:
- docker
- docker
script:
- echo http://dl-cdn.alpinelinux.org/alpine/edge/community/ >> /etc/apk/repositories
- apk update
......@@ -119,30 +118,30 @@ publish:oci-image-layout:
publish:single-binary-musl:
stage: publish
tags:
- docker
- docker
script:
- docker build -t $CI_REGISTRY_IMAGE/single-binary-musl:ci-${CI_PIPELINE_ID} -f pyinstaller/Dockerfile.alpine .
- docker run --name "single_binary_musl${CI_PIPELINE_ID}" --entrypoint "" $CI_REGISTRY_IMAGE/single-binary-musl:ci-${CI_PIPELINE_ID} echo "dummy container"
- docker cp "single_binary_musl${CI_PIPELINE_ID}":/bin/beiran beiran-single-binary-musl-${CI_COMMIT_TAG}
- docker rm "single_binary_musl${CI_PIPELINE_ID}"
- echo http://dl-cdn.alpinelinux.org/alpine/edge/community/ >> /etc/apk/repositories
# - apk update
# - apk add go=1.13.4-r0
# - apk add musl-dev
# - GO111MODULE=on go get github.com/minio/mc
# - $HOME/go/bin/mc config host add beiran https://minio.beiran.io $MINIO_ACCESS_KEY $MINIO_SECRET_KEY
# - $HOME/go/bin/mc cp beiran-single-binary-musl-${CI_COMMIT_TAG} beiran/releases
- apk update
- apk add go=1.13.4-r0
- apk add musl-dev
- GO111MODULE=on go get github.com/minio/mc
- $HOME/go/bin/mc config host add beiran https://minio.beiran.io $MINIO_ACCESS_KEY $MINIO_SECRET_KEY
- $HOME/go/bin/mc cp beiran-single-binary-musl-${CI_COMMIT_TAG} beiran/releases
artifacts:
name: "beiran-single-binary-musl"
paths:
- beiran-single-binary-musl-*
# only:
# - tags
only:
- tags
publish:single-binary-glibc:
stage: publish
tags:
- docker
- docker
script:
- docker build -t $CI_REGISTRY_IMAGE/single-binary-glibc:ci-${CI_PIPELINE_ID} -f pyinstaller/Dockerfile.stretch .
- docker run --name "single_binary_glibc${CI_PIPELINE_ID}" --entrypoint "" $CI_REGISTRY_IMAGE/single-binary-glibc:ci-${CI_PIPELINE_ID} echo "dummy container"
......@@ -162,6 +161,18 @@ publish:single-binary-glibc:
only:
- tags
publish:image:
stage: publish
tags:
- docker
script:
- docker login -u "gitlab-ci-token" -p "$CI_JOB_TOKEN" $CI_REGISTRY
- docker pull $CI_REGISTRY_IMAGE:ci-${CI_PIPELINE_ID}
- docker tag $CI_REGISTRY_IMAGE:ci-${CI_PIPELINE_ID} $CI_REGISTRY_IMAGE:${CI_COMMIT_REF_NAME}
- docker push $CI_REGISTRY_IMAGE:${CI_COMMIT_REF_NAME}
except:
- dev-0.0.9
checks:lint-beiran:
stage: checks
image: $CI_REGISTRY_IMAGE/checks:ci-${CI_PIPELINE_ID}
......