Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[CI] Build Alpine Docker images #8708

Merged
merged 8 commits into from
Jan 27, 2020
18 changes: 11 additions & 7 deletions .circleci/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -154,7 +154,7 @@ jobs:
- run: |
git clone https://github.com/crystal-lang/distribution-scripts.git ~/distribution-scripts
cd ~/distribution-scripts
git checkout 6e8201bf133ffe2dc335d2a6e895551ba6630f14
git checkout fa6db7b1361c69157be58b0c5b1b12d8e2a96561
# persist relevant information for build process
- run: |
cd ~/distribution-scripts
Expand Down Expand Up @@ -347,7 +347,7 @@ jobs:
cd /tmp/workspace/distribution-scripts
source build.env
cd docker
make all64 CRYSTAL_DEB=/tmp/workspace/build/crystal_${CRYSTAL_VERSION}-1_amd64.deb
make all64 CRYSTAL_DEB=/tmp/workspace/build/crystal_${CRYSTAL_VERSION}-1_amd64.deb CRYSTAL_TARGZ=/tmp/workspace/build/crystal-$CRYSTAL_VERSION-1-linux-x86_64.tar.gz
- persist_to_workspace:
root: /tmp/workspace/distribution-scripts/docker/
paths:
Expand Down Expand Up @@ -376,11 +376,15 @@ jobs:
- run: |
cd /tmp/workspace/distribution-scripts
source ./build.env
gunzip -c /tmp/workspace/build/docker-${CRYSTAL_VERSION}.tar.gz | docker image load
gunzip -c /tmp/workspace/build/docker-${CRYSTAL_VERSION}-build.tar.gz | docker image load
gunzip -c /tmp/workspace/build/docker-${CRYSTAL_VERSION}-ubuntu-x86_64.tar.gz | docker image load
gunzip -c /tmp/workspace/build/docker-${CRYSTAL_VERSION}-ubuntu-x86_64-build.tar.gz | docker image load
gunzip -c /tmp/workspace/build/docker-${CRYSTAL_VERSION}-alpine.tar.gz | docker image load
gunzip -c /tmp/workspace/build/docker-${CRYSTAL_VERSION}-alpine-build.tar.gz | docker image load
docker login -u ${DOCKER_USER} -p ${DOCKER_PASS}
docker push ${DOCKER_REPOSITORY}:${DOCKER_TAG}
docker push ${DOCKER_REPOSITORY}:${DOCKER_TAG}-build
docker push ${DOCKER_REPOSITORY}:${DOCKER_TAG}-alpine
docker push ${DOCKER_REPOSITORY}:${DOCKER_TAG}-alpine-build

dist_snap:
docker:
Expand Down Expand Up @@ -426,7 +430,7 @@ jobs:
cd /tmp/workspace/distribution-scripts
source build.env
cd docs
gunzip -c /tmp/workspace/build/docker-${CRYSTAL_VERSION}-build.tar.gz | docker image load
gunzip -c /tmp/workspace/build/docker-${CRYSTAL_VERSION}-ubuntu-x86_64-build.tar.gz | docker image load
make CRYSTAL_DOCKER_IMAGE=${DOCKER_REPOSITORY}:${DOCKER_TAG}-build
- store_artifacts:
path: /tmp/workspace/distribution-scripts/docs/build
Expand Down Expand Up @@ -459,7 +463,7 @@ jobs:
- run: |
cd /tmp/workspace/distribution-scripts
source ./build.env
gunzip -c /tmp/workspace/build/docker-${CRYSTAL_VERSION}.tar.gz | docker image load
gunzip -c /tmp/workspace/build/docker-${CRYSTAL_VERSION}-ubuntu-x86_64.tar.gz | docker image load
export DOCKER_TEST_PREFIX="crystallang/crystal:$DOCKER_TAG" >> $BASH_ENV
- checkout
- run: bin/ci prepare_system
Expand All @@ -480,7 +484,7 @@ jobs:
- run: |
cd /tmp/workspace/distribution-scripts
source ./build.env
gunzip -c /tmp/workspace/build/docker-${CRYSTAL_VERSION}-i386.tar.gz | docker image load
gunzip -c /tmp/workspace/build/docker-${CRYSTAL_VERSION}-ubuntu-i386.tar.gz | docker image load
export DOCKER_TEST_PREFIX="crystallang/crystal:$DOCKER_TAG-i386" >> $BASH_ENV
- checkout
- run: bin/ci prepare_system
Expand Down