Migrate to circleci 2.0
This commit is contained in:
Родитель
0a153be022
Коммит
d329c00a1a
|
@ -0,0 +1,33 @@
|
|||
# These environment variables must be set in CircleCI UI
|
||||
#
|
||||
# DOCKERHUB_REPO - docker hub repo, format: <username>/<repo>
|
||||
# DOCKER_EMAIL - login info for docker hub
|
||||
# DOCKER_USER
|
||||
# DOCKER_PASS
|
||||
|
||||
version: 2.0
|
||||
jobs:
|
||||
build-deploy:
|
||||
machine: true
|
||||
docker_layer_caching: true
|
||||
steps:
|
||||
- checkout
|
||||
- run: ./bin/build
|
||||
- run: ./bin/deploy
|
||||
integration_test:
|
||||
- run:
|
||||
name: Install Docker Compose
|
||||
command: |
|
||||
curl -L https://github.com/docker/compose/releases/download/1.19.0/docker-compose-`uname -s`-`uname -m` > ~/docker-compose
|
||||
chmod +x ~/docker-compose
|
||||
sudo mv ~/docker-compose /usr/local/bin/docker-compose
|
||||
- run: ./bin/test
|
||||
|
||||
workflows:
|
||||
version: 2
|
||||
build_test_deploy_release:
|
||||
jobs:
|
||||
- integration_test
|
||||
- build-deploy:
|
||||
requires:
|
||||
- integration_test
|
43
circle.yml
43
circle.yml
|
@ -1,43 +0,0 @@
|
|||
# These environment variables must be set in CircleCI UI
|
||||
#
|
||||
# DOCKERHUB_REPO - docker hub repo, format: <username>/<repo>
|
||||
# DOCKER_EMAIL - login info for docker hub
|
||||
# DOCKER_USER
|
||||
# DOCKER_PASS
|
||||
#
|
||||
machine:
|
||||
pre:
|
||||
# Install CircleCI's fork for Docker 1.10.0
|
||||
- curl -sSL https://s3.amazonaws.com/circle-downloads/install-circleci-docker.sh | bash -s -- 1.10.0
|
||||
- chmod -R 777 $CIRCLE_TEST_REPORTS $CIRCLE_ARTIFACTS
|
||||
services:
|
||||
- docker
|
||||
|
||||
dependencies:
|
||||
pre:
|
||||
- docker info
|
||||
- sudo apt-get update
|
||||
- sudo apt-get install python-dev
|
||||
# run tests using an upgraded version of docker-compose
|
||||
- pip install --upgrade docker-compose
|
||||
override:
|
||||
# build Docker image first to make sure it'll build correctly
|
||||
- ./bin/build
|
||||
|
||||
test:
|
||||
override:
|
||||
# run the tests using our test script
|
||||
- ./bin/test
|
||||
|
||||
deployment:
|
||||
latest:
|
||||
branch: master
|
||||
commands:
|
||||
# appropriately tag and push the container to dockerhub
|
||||
- ./bin/deploy
|
||||
|
||||
tags:
|
||||
# push all tags
|
||||
tag: /.*/
|
||||
commands:
|
||||
- ./bin/deploy
|
Загрузка…
Ссылка в новой задаче