mirror of
https://github.com/thib8956/nginx-proxy
synced 2025-02-24 09:48:14 +00:00
chore: DRY up test_dhparam.yml
Use YAML anchors for repeated values providing a single source of truth. I would use `x-*` convention to store anchors above service containers, but this seems to require a compose config that defines the services (and version?) keys, which this test setup was failing to be compatible with for some reason..
This commit is contained in:
parent
391ca3e3b5
commit
41bd4076c0
@ -7,44 +7,40 @@ web5:
|
||||
VIRTUAL_HOST: "web5.nginx-proxy.tld"
|
||||
|
||||
# sut - System Under Test
|
||||
# `docker.sock` required for functionality
|
||||
# `certs` required to enable HTTPS via template
|
||||
with_default_group:
|
||||
image: nginxproxy/nginx-proxy:test
|
||||
container_name: dh-default
|
||||
volumes:
|
||||
- /var/run/docker.sock:/tmp/docker.sock:ro
|
||||
- ./certs:/etc/nginx/certs:ro
|
||||
image: &img-nginxproxy nginxproxy/nginx-proxy:test
|
||||
volumes: &vols-common
|
||||
- &docker-sock /var/run/docker.sock:/tmp/docker.sock:ro
|
||||
- &nginx-certs ./certs:/etc/nginx/certs:ro
|
||||
|
||||
with_alternative_group:
|
||||
image: nginxproxy/nginx-proxy:test
|
||||
container_name: dh-env
|
||||
environment:
|
||||
- DHPARAM_BITS=2048
|
||||
volumes:
|
||||
- /var/run/docker.sock:/tmp/docker.sock:ro
|
||||
- ./certs:/etc/nginx/certs:ro
|
||||
image: *img-nginxproxy
|
||||
volumes: *vols-common
|
||||
|
||||
with_invalid_group:
|
||||
image: nginxproxy/nginx-proxy:test
|
||||
container_name: invalid-group-1024
|
||||
environment:
|
||||
- DHPARAM_BITS=1024
|
||||
volumes:
|
||||
- /var/run/docker.sock:/tmp/docker.sock:ro
|
||||
- ./certs:/etc/nginx/certs:ro
|
||||
image: *img-nginxproxy
|
||||
volumes: *vols-common
|
||||
|
||||
with_custom_file:
|
||||
image: nginxproxy/nginx-proxy:test
|
||||
container_name: dh-file
|
||||
volumes:
|
||||
- /var/run/docker.sock:/tmp/docker.sock:ro
|
||||
- ./certs:/etc/nginx/certs:ro
|
||||
image: *img-nginxproxy
|
||||
volumes:
|
||||
- *docker-sock
|
||||
- *nginx-certs
|
||||
- ../lib/ssl/dhparam.pem:/etc/nginx/dhparam/dhparam.pem:ro
|
||||
|
||||
with_skip:
|
||||
image: nginxproxy/nginx-proxy:test
|
||||
container_name: dh-skip
|
||||
environment:
|
||||
- DHPARAM_SKIP=1
|
||||
volumes:
|
||||
- /var/run/docker.sock:/tmp/docker.sock:ro
|
||||
- ./certs:/etc/nginx/certs:ro
|
||||
image: *img-nginxproxy
|
||||
volumes: *vols-common
|
Loading…
x
Reference in New Issue
Block a user