Fix CircleCI build
- Specify assert lines for tests to avoid btrfs errors with CircleCI - Update Docker version to 1.9.1 in CircleCI
This commit is contained in:
parent
9644c311be
commit
35c68ba7f7
5 changed files with 9 additions and 7 deletions
|
@ -1,7 +1,9 @@
|
|||
machine:
|
||||
pre:
|
||||
# install docker 1.9.1
|
||||
# install docker 1.9.1 with some CircleCI suggestions:
|
||||
# https://discuss.circleci.com/t/how-use-a-different-docker-version/298/8
|
||||
- sudo curl -L -o /usr/bin/docker 'https://s3-external-1.amazonaws.com/circle-downloads/docker-1.9.1-circleci'; sudo chmod 0755 /usr/bin/docker; true
|
||||
- sudo sed -i -e 's/ --userland-proxy=false//' /etc/default/docker
|
||||
services:
|
||||
- docker
|
||||
|
||||
|
|
|
@ -105,10 +105,10 @@ function assert_nginxproxy_behaves {
|
|||
|
||||
# Querying the proxy with Host header → 200
|
||||
run curl_container $container /data --header "Host: web1.bats"
|
||||
assert_output "answer from port 81"
|
||||
assert_output -l 0 "answer from port 81"
|
||||
|
||||
run curl_container $container /data --header "Host: web2.bats"
|
||||
assert_output "answer from port 82"
|
||||
assert_output -l 0 "answer from port 82"
|
||||
|
||||
# Querying the proxy with unknown Host header → 503
|
||||
run curl_container $container /data --header "Host: webFOO.bats" --head
|
||||
|
|
|
@ -32,9 +32,9 @@ function setup {
|
|||
|
||||
# THEN
|
||||
run curl_container $SUT_CONTAINER /data --header 'Host: multiple-hosts-1-A.bats'
|
||||
assert_output "answer from port 80"
|
||||
assert_output -l 0 "answer from port 80"
|
||||
|
||||
# THEN
|
||||
run curl_container $SUT_CONTAINER /data --header 'Host: multiple-hosts-1-B.bats'
|
||||
assert_output "answer from port 80"
|
||||
assert_output -l 0 "answer from port 80"
|
||||
}
|
||||
|
|
|
@ -52,6 +52,6 @@ function setup {
|
|||
function assert_response_is_from_port {
|
||||
local -r port=$1
|
||||
run curl_container $SUT_CONTAINER /data --header "Host: web.bats"
|
||||
assert_output "answer from port $port"
|
||||
assert_output -l 0 "answer from port $port"
|
||||
}
|
||||
|
||||
|
|
|
@ -129,6 +129,6 @@ function prepare_web_container {
|
|||
IFS=$' \t\n' # See https://github.com/sstephenson/bats/issues/89
|
||||
for port in $ports; do
|
||||
run retry 5 1s docker run --rm appropriate/curl --silent --fail http://$(docker_ip $container_name):$port/data
|
||||
assert_output "answer from port $port"
|
||||
assert_output -l 0 "answer from port $port"
|
||||
done
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue