Skip to content
This repository has been archived by the owner on Sep 12, 2024. It is now read-only.

Commit

Permalink
WIP: build with JDK11 and Docker on CircleCI
Browse files Browse the repository at this point in the history
* Upgrade docker-maven-plugin from 0.4.13 to 1.2.0
  * latest version supports Java 11
* Upgrade ssh-agent-tls from 0.0.3 to 0.0.4
* Upgrade ssh-agent-proxy from 0.1.5 to 0.2.0
  • Loading branch information
davidxia committed Oct 12, 2018
1 parent 7ab66a2 commit 49e8fa4
Show file tree
Hide file tree
Showing 2 changed files with 34 additions and 6 deletions.
30 changes: 28 additions & 2 deletions .circleci/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ jobs:
environment:
CIRCLE_ARTIFACTS: /tmp/circleci-artifacts
CIRCLE_TEST_REPORTS: /tmp/circleci-test-results
CIRCLE_MACHINE_EXECUTOR: true
MAVEN_OPTS: -Xmx128m
JAVA_VERSION: *jdk_180_version

Expand Down Expand Up @@ -66,14 +67,20 @@ jobs:
docker:
- image: spotify/helios-test-container:1
working_directory: ~/spotify/helios
parallelism: 1
parallelism: 6
shell: /bin/bash --login
environment:
CIRCLE_ARTIFACTS: /tmp/circleci-artifacts
CIRCLE_TEST_REPORTS: /tmp/circleci-test-results
MAVEN_OPTS: -Xmx128m

steps:
- checkout

- setup_remote_docker

- run: mkdir -p $CIRCLE_ARTIFACTS $CIRCLE_TEST_REPORTS

- run: ./circle.sh pre_machine

- run:
Expand All @@ -83,7 +90,26 @@ jobs:
# Without this increased timeout, downloading deps often times out.
no_output_timeout: 20m

- run: ./circle.sh verify_no_tests
- run:
command: ./circle.sh test
no_output_timeout: 20m

- run: if [ "$CIRCLE_NODE_INDEX" == "0" ]; then ./circle.sh post_test; fi

- run: ./circle.sh collect_test_reports

- store_test_results:
path: /tmp/circleci-test-results

# Save artifacts
- store_artifacts:
path: /tmp/circleci-artifacts
- store_artifacts:
path: artifacts
- store_artifacts:
path: /var/log/upstart/docker.log
- store_artifacts:
path: /tmp/circleci-test-results

workflows:
version: 2
Expand Down
10 changes: 6 additions & 4 deletions circle.sh
Original file line number Diff line number Diff line change
Expand Up @@ -33,10 +33,12 @@ case "$1" in
;;

test)
# fix DOCKER_HOST to be accessible from within containers
docker0_ip=$(/sbin/ifconfig docker0 | grep 'inet addr' | \
awk -F: '{print $2}' | awk '{print $1}')
export DOCKER_HOST="tcp://$docker0_ip:2375"
if [ -n "$CIRCLE_MACHINE_EXECUTOR" ]; then
# fix DOCKER_HOST to be accessible from within containers
docker0_ip=$(/sbin/ifconfig docker0 | grep 'inet addr' | \
awk -F: '{print $2}' | awk '{print $1}')
export DOCKER_HOST="tcp://$docker0_ip:2375"
fi

case $CIRCLE_NODE_INDEX in
0)
Expand Down

0 comments on commit 49e8fa4

Please sign in to comment.