mirror of
https://github.com/nginx-proxy/docker-letsencrypt-nginx-proxy-companion
synced 2024-11-22 20:42:04 +01:00
Merge pull request #1146 from nginx-proxy/test-compose
tests: fix docker compose use
This commit is contained in:
commit
5509d05f61
@ -1,5 +1,3 @@
|
|||||||
version: "3"
|
|
||||||
|
|
||||||
services:
|
services:
|
||||||
pebble:
|
pebble:
|
||||||
image: "ghcr.io/letsencrypt/pebble:${PEBBLE_VERSION}"
|
image: "ghcr.io/letsencrypt/pebble:${PEBBLE_VERSION}"
|
||||||
|
@ -5,7 +5,7 @@ set -e
|
|||||||
setup_pebble() {
|
setup_pebble() {
|
||||||
curl --silent --show-error https://raw.githubusercontent.com/letsencrypt/pebble/master/test/certs/pebble.minica.pem > "${GITHUB_WORKSPACE}/pebble.minica.pem"
|
curl --silent --show-error https://raw.githubusercontent.com/letsencrypt/pebble/master/test/certs/pebble.minica.pem > "${GITHUB_WORKSPACE}/pebble.minica.pem"
|
||||||
cat "${GITHUB_WORKSPACE}/pebble.minica.pem"
|
cat "${GITHUB_WORKSPACE}/pebble.minica.pem"
|
||||||
docker-compose --file "${GITHUB_WORKSPACE}/test/setup/pebble/docker-compose.yml" up --detach
|
docker compose --file "${GITHUB_WORKSPACE}/test/setup/pebble/docker-compose.yml" up --detach
|
||||||
}
|
}
|
||||||
|
|
||||||
wait_for_pebble() {
|
wait_for_pebble() {
|
||||||
@ -30,4 +30,4 @@ setup_pebble_challtestserv() {
|
|||||||
setup_pebble
|
setup_pebble
|
||||||
wait_for_pebble
|
wait_for_pebble
|
||||||
setup_pebble_challtestserv
|
setup_pebble_challtestserv
|
||||||
docker-compose --file "${GITHUB_WORKSPACE}/test/setup/pebble/docker-compose.yml" logs
|
docker compose --file "${GITHUB_WORKSPACE}/test/setup/pebble/docker-compose.yml" logs
|
||||||
|
@ -28,8 +28,8 @@ setup_boulder() {
|
|||||||
# Modify custom rate limit
|
# Modify custom rate limit
|
||||||
sed --in-place 's/le.wtf,le1.wtf/le1.wtf,le2.wtf,le3.wtf/g' test/rate-limit-policies.yml
|
sed --in-place 's/le.wtf,le1.wtf/le1.wtf,le2.wtf,le3.wtf/g' test/rate-limit-policies.yml
|
||||||
fi
|
fi
|
||||||
docker-compose build --pull
|
docker compose build --pull
|
||||||
docker-compose run -d \
|
docker compose run -d \
|
||||||
--use-aliases \
|
--use-aliases \
|
||||||
--name boulder \
|
--name boulder \
|
||||||
-e FAKE_DNS=10.77.77.1 \
|
-e FAKE_DNS=10.77.77.1 \
|
||||||
|
@ -138,13 +138,13 @@ EOF
|
|||||||
if [[ "$ACME_CA" == 'boulder' ]]; then
|
if [[ "$ACME_CA" == 'boulder' ]]; then
|
||||||
# Stop and remove Boulder
|
# Stop and remove Boulder
|
||||||
docker stop boulder
|
docker stop boulder
|
||||||
docker-compose --project-name 'boulder' \
|
docker compose --project-name 'boulder' \
|
||||||
--file "${GITHUB_WORKSPACE}/go/src/github.com/letsencrypt/boulder/docker-compose.yml" \
|
--file "${GITHUB_WORKSPACE}/go/src/github.com/letsencrypt/boulder/docker-compose.yml" \
|
||||||
down --volumes
|
down --volumes
|
||||||
docker rm boulder
|
docker rm boulder
|
||||||
elif [[ "$ACME_CA" == 'pebble' ]]; then
|
elif [[ "$ACME_CA" == 'pebble' ]]; then
|
||||||
# Stop and remove Pebble
|
# Stop and remove Pebble
|
||||||
docker-compose --file "${GITHUB_WORKSPACE}/test/setup/pebble/docker-compose.yml" down
|
docker compose --file "${GITHUB_WORKSPACE}/test/setup/pebble/docker-compose.yml" down
|
||||||
[[ -f "${GITHUB_WORKSPACE}/pebble.minica.pem" ]] && rm "${GITHUB_WORKSPACE}/pebble.minica.pem"
|
[[ -f "${GITHUB_WORKSPACE}/pebble.minica.pem" ]] && rm "${GITHUB_WORKSPACE}/pebble.minica.pem"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user