Compare commits
3 Commits
main
...
refactor-t
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
9dbb1b4153 | ||
|
|
99ee61a15d | ||
|
|
248dc28fd3 |
4
.github/dependabot.yml
vendored
4
.github/dependabot.yml
vendored
@ -5,8 +5,6 @@ updates:
|
|||||||
directory: "/"
|
directory: "/"
|
||||||
schedule:
|
schedule:
|
||||||
interval: "daily"
|
interval: "daily"
|
||||||
commit-message:
|
|
||||||
prefix: "build"
|
|
||||||
labels:
|
labels:
|
||||||
- "type/build"
|
- "type/build"
|
||||||
- "scope/dockerfile"
|
- "scope/dockerfile"
|
||||||
@ -16,7 +14,5 @@ updates:
|
|||||||
directory: "/test/requirements"
|
directory: "/test/requirements"
|
||||||
schedule:
|
schedule:
|
||||||
interval: "daily"
|
interval: "daily"
|
||||||
commit-message:
|
|
||||||
prefix: "ci"
|
|
||||||
labels:
|
labels:
|
||||||
- "type/ci"
|
- "type/ci"
|
||||||
|
|||||||
@ -1,9 +1,9 @@
|
|||||||
# setup build arguments for version of dependencies to use
|
# setup build arguments for version of dependencies to use
|
||||||
ARG DOCKER_GEN_VERSION=0.10.2
|
ARG DOCKER_GEN_VERSION=0.9.2
|
||||||
ARG FOREGO_VERSION=v0.17.0
|
ARG FOREGO_VERSION=v0.17.0
|
||||||
|
|
||||||
# Use a specific version of golang to build both binaries
|
# Use a specific version of golang to build both binaries
|
||||||
FROM golang:1.20.2 as gobuilder
|
FROM golang:1.19.4 as gobuilder
|
||||||
|
|
||||||
# Build docker-gen from scratch
|
# Build docker-gen from scratch
|
||||||
FROM gobuilder as dockergen
|
FROM gobuilder as dockergen
|
||||||
|
|||||||
@ -1,9 +1,9 @@
|
|||||||
# setup build arguments for version of dependencies to use
|
# setup build arguments for version of dependencies to use
|
||||||
ARG DOCKER_GEN_VERSION=0.10.2
|
ARG DOCKER_GEN_VERSION=0.9.2
|
||||||
ARG FOREGO_VERSION=v0.17.0
|
ARG FOREGO_VERSION=v0.17.0
|
||||||
|
|
||||||
# Use a specific version of golang to build both binaries
|
# Use a specific version of golang to build both binaries
|
||||||
FROM golang:1.20.2-alpine as gobuilder
|
FROM golang:1.19.4-alpine as gobuilder
|
||||||
RUN apk add --no-cache git musl-dev
|
RUN apk add --no-cache git musl-dev
|
||||||
|
|
||||||
# Build docker-gen from scratch
|
# Build docker-gen from scratch
|
||||||
|
|||||||
6
Makefile
6
Makefile
@ -3,13 +3,13 @@
|
|||||||
|
|
||||||
|
|
||||||
build-webserver:
|
build-webserver:
|
||||||
docker build --pull -t web test/requirements/web
|
docker build -t web test/requirements/web
|
||||||
|
|
||||||
build-nginx-proxy-test-debian:
|
build-nginx-proxy-test-debian:
|
||||||
docker build --pull --build-arg NGINX_PROXY_VERSION="test" -t nginxproxy/nginx-proxy:test .
|
docker build --build-arg NGINX_PROXY_VERSION="test" -t nginxproxy/nginx-proxy:test .
|
||||||
|
|
||||||
build-nginx-proxy-test-alpine:
|
build-nginx-proxy-test-alpine:
|
||||||
docker build --pull --build-arg NGINX_PROXY_VERSION="test" -f Dockerfile.alpine -t nginxproxy/nginx-proxy:test .
|
docker build --build-arg NGINX_PROXY_VERSION="test" -f Dockerfile.alpine -t nginxproxy/nginx-proxy:test .
|
||||||
|
|
||||||
test-debian: build-webserver build-nginx-proxy-test-debian
|
test-debian: build-webserver build-nginx-proxy-test-debian
|
||||||
test/pytest.sh
|
test/pytest.sh
|
||||||
|
|||||||
128
README.md
128
README.md
@ -152,17 +152,10 @@ The filename of the previous example would be `example.tld_8610f6c344b4096614eab
|
|||||||
|
|
||||||
This environment variable of the nginx proxy container can be used to customize the return error page if no matching path is found. Furthermore it is possible to use anything which is compatible with the `return` statement of nginx.
|
This environment variable of the nginx proxy container can be used to customize the return error page if no matching path is found. Furthermore it is possible to use anything which is compatible with the `return` statement of nginx.
|
||||||
|
|
||||||
Exception: If this is set to the string `none`, no default `location /` directive will be generated. This makes it possible for you to provide your own `location /` directive in your [`/etc/nginx/vhost.d/VIRTUAL_HOST`](#per-virtual_host) or [`/etc/nginx/vhost.d/default`](#per-virtual_host-default-configuration) files.
|
For example `DEFAULT_ROOT=418` will return a 418 error page instead of the normal 404 one.
|
||||||
|
Another example is `DEFAULT_ROOT="301 https://github.com/nginx-proxy/nginx-proxy/blob/main/README.md"` which would redirect an invalid request to this documentation.
|
||||||
If unspecified, `DEFAULT_ROOT` defaults to `404`.
|
Nginx variables such as $scheme, $host, and $request_uri can be used. However, care must be taken to make sure the $ signs are escaped properly.
|
||||||
|
If you want to use `301 $scheme://$host/myapp1$request_uri` you should use:
|
||||||
Examples (YAML syntax):
|
|
||||||
|
|
||||||
* `DEFAULT_ROOT: "none"` prevents `nginx-proxy` from generating a default `location /` directive.
|
|
||||||
* `DEFAULT_ROOT: "418"` returns a 418 error page instead of the normal 404 one.
|
|
||||||
* `DEFAULT_ROOT: "301 https://github.com/nginx-proxy/nginx-proxy/blob/main/README.md"` redirects the client to this documentation.
|
|
||||||
|
|
||||||
Nginx variables such as `$scheme`, `$host`, and `$request_uri` can be used. However, care must be taken to make sure the `$` signs are escaped properly. For example, if you want to use `301 $scheme://$host/myapp1$request_uri` you should use:
|
|
||||||
|
|
||||||
* Bash: `DEFAULT_ROOT='301 $scheme://$host/myapp1$request_uri'`
|
* Bash: `DEFAULT_ROOT='301 $scheme://$host/myapp1$request_uri'`
|
||||||
* Docker Compose yaml: `- DEFAULT_ROOT: 301 $$scheme://$$host/myapp1$$request_uri`
|
* Docker Compose yaml: `- DEFAULT_ROOT: 301 $$scheme://$$host/myapp1$$request_uri`
|
||||||
@ -227,11 +220,6 @@ If you would like to connect to FastCGI backend, set `VIRTUAL_PROTO=fastcgi` on
|
|||||||
|
|
||||||
If you use fastcgi,you can set `VIRTUAL_ROOT=xxx` for your root directory
|
If you use fastcgi,you can set `VIRTUAL_ROOT=xxx` for your root directory
|
||||||
|
|
||||||
### Custom log format
|
|
||||||
|
|
||||||
If you want to use a custom log format, you can set `LOG_FORMAT=xxx` on the proxy container.
|
|
||||||
|
|
||||||
With docker compose take care to escape the `$` character with `$$` to avoid variable interpolation. Example: `$remote_addr` becomes `$$remote_addr`.
|
|
||||||
|
|
||||||
### Default Host
|
### Default Host
|
||||||
|
|
||||||
@ -347,9 +335,10 @@ Note that the `Mozilla-Old` policy should use a 1024 bits DH key for compatibili
|
|||||||
|
|
||||||
The default behavior for the proxy when port 80 and 443 are exposed is as follows:
|
The default behavior for the proxy when port 80 and 443 are exposed is as follows:
|
||||||
|
|
||||||
* If a virtual host has a usable cert, port 80 will redirect to 443 for that virtual host so that HTTPS is always preferred when available.
|
* If a container has a usable cert, port 80 will redirect to 443 for that container so that HTTPS is always preferred when available.
|
||||||
* If the virtual host does not have a usable cert, but `default.crt` and `default.key` exist, those will be used as the virtual host's certificate and the client browser will receive a 500 error.
|
* If the container does not have a usable cert, a 503 will be returned.
|
||||||
* If the virtual host does not have a usable cert, and `default.crt` and `default.key` do not exist, TLS negotiation will fail (see [Missing Certificate](#missing-certificate) below).
|
|
||||||
|
Note that in the latter case, a browser may get an connection error as no certificate is available to establish a connection. A self-signed or generic cert named `default.crt` and `default.key` will allow a client browser to make a SSL connection (likely w/ a warning) and subsequently receive a 500.
|
||||||
|
|
||||||
To serve traffic in both SSL and non-SSL modes without redirecting to SSL, you can include the environment variable `HTTPS_METHOD=noredirect` (the default is `HTTPS_METHOD=redirect`). You can also disable the non-SSL site entirely with `HTTPS_METHOD=nohttp`, or disable the HTTPS site with `HTTPS_METHOD=nohttps`. `HTTPS_METHOD` can be specified on each container for which you want to override the default behavior or on the proxy container to set it globally. If `HTTPS_METHOD=noredirect` is used, Strict Transport Security (HSTS) is disabled to prevent HTTPS users from being redirected by the client. If you cannot get to the HTTP site after changing this setting, your browser has probably cached the HSTS policy and is automatically redirecting you back to HTTPS. You will need to clear your browser's HSTS cache or use an incognito window / different browser.
|
To serve traffic in both SSL and non-SSL modes without redirecting to SSL, you can include the environment variable `HTTPS_METHOD=noredirect` (the default is `HTTPS_METHOD=redirect`). You can also disable the non-SSL site entirely with `HTTPS_METHOD=nohttp`, or disable the HTTPS site with `HTTPS_METHOD=nohttps`. `HTTPS_METHOD` can be specified on each container for which you want to override the default behavior or on the proxy container to set it globally. If `HTTPS_METHOD=noredirect` is used, Strict Transport Security (HSTS) is disabled to prevent HTTPS users from being redirected by the client. If you cannot get to the HTTP site after changing this setting, your browser has probably cached the HSTS policy and is automatically redirecting you back to HTTPS. You will need to clear your browser's HSTS cache or use an incognito window / different browser.
|
||||||
|
|
||||||
@ -357,31 +346,6 @@ By default, [HTTP Strict Transport Security (HSTS)](https://developer.mozilla.or
|
|||||||
|
|
||||||
*WARNING*: HSTS will force your users to visit the HTTPS version of your site for the `max-age` time - even if they type in `http://` manually. The only way to get to an HTTP site after receiving an HSTS response is to clear your browser's HSTS cache.
|
*WARNING*: HSTS will force your users to visit the HTTPS version of your site for the `max-age` time - even if they type in `http://` manually. The only way to get to an HTTP site after receiving an HSTS response is to clear your browser's HSTS cache.
|
||||||
|
|
||||||
#### Missing Certificate
|
|
||||||
|
|
||||||
If HTTPS is enabled for a virtual host but its certificate is missing, nginx-proxy will configure nginx to use the default certificate (`default.crt` with `default.key`) and return a 500 error.
|
|
||||||
|
|
||||||
If the default certificate is also missing, nginx-proxy will configure nginx to accept HTTPS connections but fail the TLS negotiation. Client browsers will render a TLS error page. As of March 2023, web browsers display the following error messages:
|
|
||||||
|
|
||||||
* Chrome:
|
|
||||||
|
|
||||||
> This site can't provide a secure connection
|
|
||||||
>
|
|
||||||
> example.test sent an invalid response.
|
|
||||||
>
|
|
||||||
> Try running Connectivity Diagnostics.
|
|
||||||
>
|
|
||||||
> `ERR_SSL_PROTOCOL_ERROR`
|
|
||||||
|
|
||||||
* Firefox:
|
|
||||||
|
|
||||||
> Secure Connection Failed
|
|
||||||
>
|
|
||||||
> An error occurred during a connection to example.test.
|
|
||||||
> Peer reports it experienced an internal error.
|
|
||||||
>
|
|
||||||
> Error code: `SSL_ERROR_INTERNAL_ERROR_ALERT` "TLS error".
|
|
||||||
|
|
||||||
### Basic Authentication Support
|
### Basic Authentication Support
|
||||||
|
|
||||||
In order to be able to secure your virtual host, you have to create a file named as its equivalent VIRTUAL_HOST variable on directory
|
In order to be able to secure your virtual host, you have to create a file named as its equivalent VIRTUAL_HOST variable on directory
|
||||||
@ -397,49 +361,6 @@ docker run -d -p 80:80 -p 443:443 \
|
|||||||
|
|
||||||
You'll need apache2-utils on the machine where you plan to create the htpasswd file. Follow these [instructions](http://httpd.apache.org/docs/2.2/programs/htpasswd.html)
|
You'll need apache2-utils on the machine where you plan to create the htpasswd file. Follow these [instructions](http://httpd.apache.org/docs/2.2/programs/htpasswd.html)
|
||||||
|
|
||||||
### Upstream (Backend) Server HTTP Load Balancing Support
|
|
||||||
|
|
||||||
> **Warning**
|
|
||||||
> This feature is experimental. The behavior may change (or the feature may be removed entirely) without warning in a future release, even if the release is not a new major version. If you use this feature, or if you would like to use this feature but you require changes to it first, please [provide feedback in #2195](https://github.com/nginx-proxy/nginx-proxy/discussions/2195). Once we have collected enough feedback we will promote this feature to officially supported.
|
|
||||||
|
|
||||||
If you have multiple containers with the same `VIRTUAL_HOST` and `VIRTUAL_PATH` settings, nginx will spread the load across all of them. To change the load balancing algorithm from nginx's default (round-robin), set the `com.github.nginx-proxy.nginx-proxy.loadbalance` label on one or more of your application containers to the desired load balancing directive. See the [`ngx_http_upstream_module` documentation](https://nginx.org/en/docs/http/ngx_http_upstream_module.html) for available directives.
|
|
||||||
|
|
||||||
> **Note**
|
|
||||||
> * Don't forget the terminating semicolon (`;`).
|
|
||||||
> * If you are using Docker Compose, remember to escape any dollar sign (`$`) characters (`$` becomes `$$`).
|
|
||||||
|
|
||||||
Docker Compose example:
|
|
||||||
|
|
||||||
```yaml
|
|
||||||
services:
|
|
||||||
nginx-proxy:
|
|
||||||
image: nginxproxy/nginx-proxy
|
|
||||||
ports:
|
|
||||||
- "80:80"
|
|
||||||
volumes:
|
|
||||||
- /var/run/docker.sock:/tmp/docker.sock:ro
|
|
||||||
environment:
|
|
||||||
HTTPS_METHOD: nohttps
|
|
||||||
myapp:
|
|
||||||
image: jwilder/whoami
|
|
||||||
expose:
|
|
||||||
- "8000"
|
|
||||||
environment:
|
|
||||||
VIRTUAL_HOST: myapp.example
|
|
||||||
VIRTUAL_PORT: "8000"
|
|
||||||
labels:
|
|
||||||
com.github.nginx-proxy.nginx-proxy.loadbalance: "hash $$remote_addr;"
|
|
||||||
deploy:
|
|
||||||
replicas: 4
|
|
||||||
```
|
|
||||||
|
|
||||||
### Upstream (Backend) Server HTTP Keep-Alive Support
|
|
||||||
|
|
||||||
> **Warning**
|
|
||||||
> This feature is experimental. The behavior may change (or the feature may be removed entirely) without warning in a future release, even if the release is not a new major version. If you use this feature, or if you would like to use this feature but you require changes to it first, please [provide feedback in #2194](https://github.com/nginx-proxy/nginx-proxy/discussions/2194). Once we have collected enough feedback we will promote this feature to officially supported.
|
|
||||||
|
|
||||||
To enable HTTP keep-alive between `nginx-proxy` and a backend server, set the `com.github.nginx-proxy.nginx-proxy.keepalive` label on the server's container to the desired maximum number of idle connections. See the [nginx keepalive documentation](https://nginx.org/en/docs/http/ngx_http_upstream_module.html#keepalive) and the [Docker label documentation](https://docs.docker.com/config/labels-custom-metadata/) for details.
|
|
||||||
|
|
||||||
### Headers
|
### Headers
|
||||||
|
|
||||||
By default, `nginx-proxy` forwards all incoming request headers from the client to the backend server unmodified, with the following exceptions:
|
By default, `nginx-proxy` forwards all incoming request headers from the client to the backend server unmodified, with the following exceptions:
|
||||||
@ -558,32 +479,6 @@ ln -s /path/to/vhost.d/www.example.com /path/to/vhost.d/example.com
|
|||||||
|
|
||||||
If you want most of your virtual hosts to use a default single `location` block configuration and then override on a few specific ones, add those settings to the `/etc/nginx/vhost.d/default_location` file. This file will be used on any virtual host which does not have a `/etc/nginx/vhost.d/{VIRTUAL_HOST}_location` file associated with it.
|
If you want most of your virtual hosts to use a default single `location` block configuration and then override on a few specific ones, add those settings to the `/etc/nginx/vhost.d/default_location` file. This file will be used on any virtual host which does not have a `/etc/nginx/vhost.d/{VIRTUAL_HOST}_location` file associated with it.
|
||||||
|
|
||||||
#### Overriding `location` blocks
|
|
||||||
|
|
||||||
The `${VIRTUAL_HOST}_${PATH_HASH}_location`, `${VIRTUAL_HOST}_location`, and `default_location` files documented above make it possible to *augment* the generated [`location` block(s)](https://nginx.org/en/docs/http/ngx_http_core_module.html#location) in a virtual host. In some circumstances, you may need to *completely override* the `location` block for a particular combination of virtual host and path. To do this, create a file whose name follows this pattern:
|
|
||||||
|
|
||||||
```
|
|
||||||
/etc/nginx/vhost.d/${VIRTUAL_HOST}_${PATH_HASH}_location_override
|
|
||||||
```
|
|
||||||
|
|
||||||
where `${VIRTUAL_HOST}` is the name of the virtual host (the `VIRTUAL_HOST` environment variable) and `${PATH_HASH}` is the SHA-1 hash of the path, as [described above](#per-virtual_path-location-configuration).
|
|
||||||
|
|
||||||
For convenience, the `_${PATH_HASH}` part can be omitted if the path is `/`:
|
|
||||||
|
|
||||||
```
|
|
||||||
/etc/nginx/vhost.d/${VIRTUAL_HOST}_location_override
|
|
||||||
```
|
|
||||||
|
|
||||||
When an override file exists, the `location` block that is normally created by `nginx-proxy` is not generated. Instead, the override file is included via the [nginx `include` directive](https://nginx.org/en/docs/ngx_core_module.html#include).
|
|
||||||
|
|
||||||
You are responsible for providing a suitable `location` block in your override file as required for your service. By default, `nginx-proxy` uses the `VIRTUAL_HOST` name as the upstream name for your application's Docker container; see [here](#unhashed-vs-sha1-upstream-names) for details. As an example, if your container has a `VIRTUAL_HOST` value of `app.example.com`, then to override the location block for `/` you would create a file named `/etc/nginx/vhost.d/app.example.com_location_override` that contains something like this:
|
|
||||||
|
|
||||||
```
|
|
||||||
location / {
|
|
||||||
proxy_pass http://app.example.com;
|
|
||||||
}
|
|
||||||
```
|
|
||||||
|
|
||||||
#### Per-VIRTUAL_HOST `server_tokens` configuration
|
#### Per-VIRTUAL_HOST `server_tokens` configuration
|
||||||
Per virtual-host `servers_tokens` directive can be configured by passing appropriate value to the `SERVER_TOKENS` environment variable. Please see the [nginx http_core module configuration](https://nginx.org/en/docs/http/ngx_http_core_module.html#server_tokens) for more details.
|
Per virtual-host `servers_tokens` directive can be configured by passing appropriate value to the `SERVER_TOKENS` environment variable. Please see the [nginx http_core module configuration](https://nginx.org/en/docs/http/ngx_http_core_module.html#server_tokens) for more details.
|
||||||
|
|
||||||
@ -595,13 +490,12 @@ Please note that using regular expressions in `VIRTUAL_HOST` will always result
|
|||||||
|
|
||||||
### Troubleshooting
|
### Troubleshooting
|
||||||
|
|
||||||
If you can't access your `VIRTUAL_HOST`, inspect the generated nginx configuration:
|
In case you can't access your VIRTUAL_HOST, set `DEBUG=true` in the client container's environment and have a look at the generated nginx configuration file `/etc/nginx/conf.d/default.conf`:
|
||||||
|
|
||||||
```console
|
```console
|
||||||
docker exec <nginx-proxy-instance> nginx -T
|
docker exec <nginx-proxy-instance> cat /etc/nginx/conf.d/default.conf
|
||||||
```
|
```
|
||||||
|
Especially at `upstream` definition blocks which should look like:
|
||||||
Pay attention to the `upstream` definition blocks, which should look like this:
|
|
||||||
|
|
||||||
```Nginx
|
```Nginx
|
||||||
# foo.example.com
|
# foo.example.com
|
||||||
|
|||||||
1015
nginx.tmpl
1015
nginx.tmpl
File diff suppressed because it is too large
Load Diff
@ -322,28 +322,31 @@ def wait_for_nginxproxy_to_be_ready():
|
|||||||
logging.debug("nginx-proxy ready")
|
logging.debug("nginx-proxy ready")
|
||||||
break
|
break
|
||||||
|
|
||||||
|
def find_docker_compose_file(request):
|
||||||
|
"""
|
||||||
|
helper for fixture functions to figure out the name of the docker-compose file to consider.
|
||||||
|
|
||||||
@pytest.fixture
|
- if the test module provides a `docker_compose_file` variable, take that
|
||||||
def docker_compose_file(request):
|
- else, if a yaml file exists with the same name as the test module (but for the `.yml` extension), use that
|
||||||
"""Fixture naming the docker-compose file to consider.
|
- otherwise use `docker-compose.yml`.
|
||||||
|
|
||||||
If a YAML file exists with the same name as the test module (with the `.py` extension replaced
|
|
||||||
with `.yml` or `.yaml`), use that. Otherwise, use `docker-compose.yml` in the same directory
|
|
||||||
as the test module.
|
|
||||||
|
|
||||||
Tests can override this fixture to specify a custom location.
|
|
||||||
"""
|
"""
|
||||||
test_module_dir = os.path.dirname(request.module.__file__)
|
test_module_dir = os.path.dirname(request.module.__file__)
|
||||||
yml_file = os.path.join(test_module_dir, request.module.__name__ + '.yml')
|
yml_file = os.path.join(test_module_dir, request.module.__name__ + '.yml')
|
||||||
yaml_file = os.path.join(test_module_dir, request.module.__name__ + '.yaml')
|
yaml_file = os.path.join(test_module_dir, request.module.__name__ + '.yaml')
|
||||||
default_file = os.path.join(test_module_dir, 'docker-compose.yml')
|
default_file = os.path.join(test_module_dir, 'docker-compose.yml')
|
||||||
|
|
||||||
if os.path.isfile(yml_file):
|
docker_compose_file_module_variable = getattr(request.module, "docker_compose_file", None)
|
||||||
docker_compose_file = yml_file
|
if docker_compose_file_module_variable is not None:
|
||||||
elif os.path.isfile(yaml_file):
|
docker_compose_file = os.path.join( test_module_dir, docker_compose_file_module_variable)
|
||||||
docker_compose_file = yaml_file
|
if not os.path.isfile(docker_compose_file):
|
||||||
|
raise ValueError(f"docker compose file {docker_compose_file!r} could not be found. Check your test module `docker_compose_file` variable value.")
|
||||||
else:
|
else:
|
||||||
docker_compose_file = default_file
|
if os.path.isfile(yml_file):
|
||||||
|
docker_compose_file = yml_file
|
||||||
|
elif os.path.isfile(yaml_file):
|
||||||
|
docker_compose_file = yaml_file
|
||||||
|
else:
|
||||||
|
docker_compose_file = default_file
|
||||||
|
|
||||||
if not os.path.isfile(docker_compose_file):
|
if not os.path.isfile(docker_compose_file):
|
||||||
logging.error("Could not find any docker-compose file named either '{0}.yml', '{0}.yaml' or 'docker-compose.yml'".format(request.module.__name__))
|
logging.error("Could not find any docker-compose file named either '{0}.yml', '{0}.yaml' or 'docker-compose.yml'".format(request.module.__name__))
|
||||||
@ -416,72 +419,34 @@ def connect_to_all_networks():
|
|||||||
return [connect_to_network(network) for network in networks]
|
return [connect_to_network(network) for network in networks]
|
||||||
|
|
||||||
|
|
||||||
class DockerComposer(contextlib.AbstractContextManager):
|
|
||||||
def __init__(self):
|
|
||||||
self._docker_compose_file = None
|
|
||||||
|
|
||||||
def __exit__(self, *exc_info):
|
|
||||||
self._down()
|
|
||||||
|
|
||||||
def _down(self):
|
|
||||||
if self._docker_compose_file is None:
|
|
||||||
return
|
|
||||||
for network in self._networks:
|
|
||||||
disconnect_from_network(network)
|
|
||||||
docker_compose_down(self._docker_compose_file)
|
|
||||||
self._docker_compose_file = None
|
|
||||||
|
|
||||||
def compose(self, docker_compose_file):
|
|
||||||
if docker_compose_file == self._docker_compose_file:
|
|
||||||
return
|
|
||||||
self._down()
|
|
||||||
if docker_compose_file is None:
|
|
||||||
return
|
|
||||||
remove_all_containers()
|
|
||||||
docker_compose_up(docker_compose_file)
|
|
||||||
self._networks = connect_to_all_networks()
|
|
||||||
wait_for_nginxproxy_to_be_ready()
|
|
||||||
time.sleep(3) # give time to containers to be ready
|
|
||||||
self._docker_compose_file = docker_compose_file
|
|
||||||
|
|
||||||
|
|
||||||
###############################################################################
|
###############################################################################
|
||||||
#
|
#
|
||||||
# Py.test fixtures
|
# Py.test fixtures
|
||||||
#
|
#
|
||||||
###############################################################################
|
###############################################################################
|
||||||
|
|
||||||
|
|
||||||
@pytest.fixture(scope="module")
|
@pytest.fixture(scope="module")
|
||||||
def docker_composer():
|
def docker_compose(request):
|
||||||
with DockerComposer() as d:
|
"""
|
||||||
yield d
|
pytest fixture providing containers described in a docker compose file. After the tests, remove the created containers
|
||||||
|
|
||||||
|
A custom docker compose file name can be defined in a variable named `docker_compose_file`.
|
||||||
@pytest.fixture
|
|
||||||
def ca_root_certificate():
|
|
||||||
return CA_ROOT_CERTIFICATE
|
|
||||||
|
|
||||||
|
|
||||||
@pytest.fixture
|
|
||||||
def monkey_patched_dns():
|
|
||||||
original_dns_resolver = monkey_patch_urllib_dns_resolver()
|
|
||||||
yield
|
|
||||||
restore_urllib_dns_resolver(original_dns_resolver)
|
|
||||||
|
|
||||||
|
|
||||||
@pytest.fixture
|
|
||||||
def docker_compose(monkey_patched_dns, docker_composer, docker_compose_file):
|
|
||||||
"""Ensures containers described in a docker compose file are started.
|
|
||||||
|
|
||||||
A custom docker compose file name can be specified by overriding the `docker_compose_file`
|
|
||||||
fixture.
|
|
||||||
|
|
||||||
Also, in the case where pytest is running from a docker container, this fixture makes sure
|
Also, in the case where pytest is running from a docker container, this fixture makes sure
|
||||||
our container will be attached to all the docker networks.
|
our container will be attached to all the docker networks.
|
||||||
"""
|
"""
|
||||||
docker_composer.compose(docker_compose_file)
|
docker_compose_file = find_docker_compose_file(request)
|
||||||
|
original_dns_resolver = monkey_patch_urllib_dns_resolver()
|
||||||
|
remove_all_containers()
|
||||||
|
docker_compose_up(docker_compose_file)
|
||||||
|
networks = connect_to_all_networks()
|
||||||
|
wait_for_nginxproxy_to_be_ready()
|
||||||
|
time.sleep(3) # give time to containers to be ready
|
||||||
yield docker_client
|
yield docker_client
|
||||||
|
for network in networks:
|
||||||
|
disconnect_from_network(network)
|
||||||
|
docker_compose_down(docker_compose_file)
|
||||||
|
restore_urllib_dns_resolver(original_dns_resolver)
|
||||||
|
|
||||||
|
|
||||||
@pytest.fixture()
|
@pytest.fixture()
|
||||||
|
|||||||
@ -1,4 +1,4 @@
|
|||||||
#!/bin/sh
|
#!/bin/bash
|
||||||
###############################################################################
|
###############################################################################
|
||||||
# #
|
# #
|
||||||
# This script is meant to run the test suite from a Docker container. #
|
# This script is meant to run the test suite from a Docker container. #
|
||||||
@ -9,20 +9,17 @@
|
|||||||
###############################################################################
|
###############################################################################
|
||||||
|
|
||||||
# Returns the absolute directory path to this script
|
# Returns the absolute directory path to this script
|
||||||
TESTDIR=$(cd "${0%/*}" && pwd) || exit 1
|
DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )"
|
||||||
DIR=$(cd "${TESTDIR}/.." && pwd) || exit 1
|
ARGS=("$@")
|
||||||
|
|
||||||
# check requirements
|
# check requirements
|
||||||
echo "> Building nginx-proxy-tester image..."
|
echo "> Building nginx-proxy-tester image..."
|
||||||
docker build --pull -t nginx-proxy-tester \
|
docker build -t nginx-proxy-tester -f "${DIR}/requirements/Dockerfile-nginx-proxy-tester" "${DIR}/requirements"
|
||||||
-f "${TESTDIR}/requirements/Dockerfile-nginx-proxy-tester" \
|
|
||||||
"${TESTDIR}/requirements" \
|
|
||||||
|| exit 1
|
|
||||||
|
|
||||||
# run the nginx-proxy-tester container setting the correct value for the working dir in order for
|
# run the nginx-proxy-tester container setting the correct value for the working dir in order for
|
||||||
# docker-compose to work properly when run from within that container.
|
# docker-compose to work properly when run from within that container.
|
||||||
exec docker run --rm -it --name "nginx-proxy-pytest" \
|
exec docker run --rm -it --name "nginx-proxy-pytest" \
|
||||||
--volume "/var/run/docker.sock:/var/run/docker.sock" \
|
--volume "/var/run/docker.sock:/var/run/docker.sock" \
|
||||||
--volume "${DIR}:${DIR}" \
|
--volume "${DIR}:${DIR}" \
|
||||||
--workdir "${TESTDIR}" \
|
--workdir "${DIR}" \
|
||||||
nginx-proxy-tester "$@"
|
nginx-proxy-tester "${ARGS[@]}"
|
||||||
@ -1,5 +1,5 @@
|
|||||||
backoff==2.2.1
|
backoff==2.2.1
|
||||||
docker-compose==1.29.2
|
docker-compose==1.29.2
|
||||||
docker==6.0.1
|
docker==6.0.1
|
||||||
pytest==7.2.2
|
pytest==7.2.0
|
||||||
requests==2.28.2
|
requests==2.28.1
|
||||||
|
|||||||
@ -10,6 +10,8 @@ web:
|
|||||||
reverseproxy:
|
reverseproxy:
|
||||||
image: nginxproxy/nginx-proxy:test
|
image: nginxproxy/nginx-proxy:test
|
||||||
container_name: reverseproxy
|
container_name: reverseproxy
|
||||||
|
environment:
|
||||||
|
DEBUG: "true"
|
||||||
volumes:
|
volumes:
|
||||||
- /var/run/docker.sock:/tmp/docker.sock:ro
|
- /var/run/docker.sock:/tmp/docker.sock:ro
|
||||||
- ./tmp_certs:/etc/nginx/certs:ro
|
- ./tmp_certs:/etc/nginx/certs:ro
|
||||||
12
test/test_debug/test_proxy-debug-flag.py
Normal file
12
test/test_debug/test_proxy-debug-flag.py
Normal file
@ -0,0 +1,12 @@
|
|||||||
|
import pytest
|
||||||
|
import re
|
||||||
|
|
||||||
|
def test_debug_info_is_present_in_nginx_generated_conf(docker_compose, nginxproxy):
|
||||||
|
conf = nginxproxy.get_conf().decode('ASCII')
|
||||||
|
assert re.search(r"# Exposed ports: \[\{\d+\.\d+\.\d+\.\d+\s+80\s+tcp \} \{\d+\.\d+\.\d+\.\d+\s+81\s+tcp \}\]", conf) or \
|
||||||
|
re.search(r"# Exposed ports: \[\{\d+\.\d+\.\d+\.\d+\s+81\s+tcp \} \{\d+\.\d+\.\d+\.\d+\s+80\s+tcp \}\]", conf)
|
||||||
|
assert re.search(r"# Exposed ports: \[\{\d+\.\d+\.\d+\.\d+\s+82\s+tcp \} \{\d+\.\d+\.\d+\.\d+\s+83\s+tcp \}\]", conf) or \
|
||||||
|
re.search(r"# Exposed ports: \[\{\d+\.\d+\.\d+\.\d+\s+83\s+tcp \} \{\d+\.\d+\.\d+\.\d+\s+82\s+tcp \}\]", conf)
|
||||||
|
assert "# Default virtual port: 80" in conf
|
||||||
|
assert "# VIRTUAL_PORT: 82" in conf
|
||||||
|
assert conf.count("# /!\\ Virtual port not exposed") == 1
|
||||||
26
test/test_debug/test_proxy-debug-flag.yml
Normal file
26
test/test_debug/test_proxy-debug-flag.yml
Normal file
@ -0,0 +1,26 @@
|
|||||||
|
web1:
|
||||||
|
image: web
|
||||||
|
expose:
|
||||||
|
- "80"
|
||||||
|
- "81"
|
||||||
|
environment:
|
||||||
|
WEB_PORTS: "80 81"
|
||||||
|
VIRTUAL_HOST: "web1.nginx-proxy.tld"
|
||||||
|
VIRTUAL_PORT: "82"
|
||||||
|
|
||||||
|
web2:
|
||||||
|
image: web
|
||||||
|
expose:
|
||||||
|
- "82"
|
||||||
|
- "83"
|
||||||
|
environment:
|
||||||
|
WEB_PORTS: "82 83"
|
||||||
|
VIRTUAL_HOST: "web2.nginx-proxy.tld"
|
||||||
|
VIRTUAL_PORT: "82"
|
||||||
|
|
||||||
|
sut:
|
||||||
|
image: nginxproxy/nginx-proxy:test
|
||||||
|
volumes:
|
||||||
|
- /var/run/docker.sock:/tmp/docker.sock:ro
|
||||||
|
environment:
|
||||||
|
DEBUG: "true"
|
||||||
8
test/test_debug/test_server-debug-flag.py
Normal file
8
test/test_debug/test_server-debug-flag.py
Normal file
@ -0,0 +1,8 @@
|
|||||||
|
import pytest
|
||||||
|
import re
|
||||||
|
|
||||||
|
def test_debug_info_is_present_in_nginx_generated_conf(docker_compose, nginxproxy):
|
||||||
|
conf = nginxproxy.get_conf().decode('ASCII')
|
||||||
|
assert re.search(r"# Exposed ports: \[\{\d+\.\d+\.\d+\.\d+\s+80\s+tcp \} \{\d+\.\d+\.\d+\.\d+\s+81\s+tcp \}\]", conf) or \
|
||||||
|
re.search(r"# Exposed ports: \[\{\d+\.\d+\.\d+\.\d+\s+81\s+tcp \} \{\d+\.\d+\.\d+\.\d+\s+80\s+tcp \}\]", conf)
|
||||||
|
assert conf.count("# Exposed ports: [{") == 1
|
||||||
25
test/test_debug/test_server-debug-flag.yml
Normal file
25
test/test_debug/test_server-debug-flag.yml
Normal file
@ -0,0 +1,25 @@
|
|||||||
|
web1:
|
||||||
|
image: web
|
||||||
|
expose:
|
||||||
|
- "80"
|
||||||
|
- "81"
|
||||||
|
environment:
|
||||||
|
WEB_PORTS: "80 81"
|
||||||
|
VIRTUAL_HOST: "web1.nginx-proxy.tld"
|
||||||
|
VIRTUAL_PORT: "82"
|
||||||
|
DEBUG: "true"
|
||||||
|
|
||||||
|
web2:
|
||||||
|
image: web
|
||||||
|
expose:
|
||||||
|
- "82"
|
||||||
|
- "83"
|
||||||
|
environment:
|
||||||
|
WEB_PORTS: "82 83"
|
||||||
|
VIRTUAL_HOST: "web2.nginx-proxy.tld"
|
||||||
|
VIRTUAL_PORT: "82"
|
||||||
|
|
||||||
|
sut:
|
||||||
|
image: nginxproxy/nginx-proxy:test
|
||||||
|
volumes:
|
||||||
|
- /var/run/docker.sock:/tmp/docker.sock:ro
|
||||||
@ -1,8 +0,0 @@
|
|||||||
import re
|
|
||||||
|
|
||||||
|
|
||||||
def test_default_root_none(docker_compose, nginxproxy):
|
|
||||||
conf = nginxproxy.get_conf().decode()
|
|
||||||
assert re.search(r"(?m)^\s*location\s+/path\s+\{", conf)
|
|
||||||
assert not re.search(r"(?m)^\s*location\s+/\s+\{", conf)
|
|
||||||
|
|
||||||
@ -1,15 +0,0 @@
|
|||||||
services:
|
|
||||||
sut:
|
|
||||||
image: nginxproxy/nginx-proxy:test
|
|
||||||
volumes:
|
|
||||||
- /var/run/docker.sock:/tmp/docker.sock:ro
|
|
||||||
environment:
|
|
||||||
DEFAULT_ROOT: none
|
|
||||||
web:
|
|
||||||
image: web
|
|
||||||
expose:
|
|
||||||
- "80"
|
|
||||||
environment:
|
|
||||||
WEB_PORTS: "80"
|
|
||||||
VIRTUAL_HOST: web.nginx-proxy.test
|
|
||||||
VIRTUAL_PATH: /path
|
|
||||||
@ -1,9 +1,41 @@
|
|||||||
def test_unknown_virtual_host_is_503(docker_compose, nginxproxy):
|
import os
|
||||||
|
import docker
|
||||||
|
import logging
|
||||||
|
import pytest
|
||||||
|
|
||||||
|
|
||||||
|
@pytest.fixture(scope="module")
|
||||||
|
def nginx_tmpl():
|
||||||
|
"""
|
||||||
|
pytest fixture which extracts the the nginx config template from
|
||||||
|
the nginxproxy/nginx-proxy:test image
|
||||||
|
"""
|
||||||
|
script_dir = os.path.dirname(__file__)
|
||||||
|
logging.info("extracting nginx.tmpl from nginxproxy/nginx-proxy:test")
|
||||||
|
docker_client = docker.from_env()
|
||||||
|
print(
|
||||||
|
docker_client.containers.run(
|
||||||
|
image="nginxproxy/nginx-proxy:test",
|
||||||
|
remove=True,
|
||||||
|
volumes=["{current_dir}:{current_dir}".format(current_dir=script_dir)],
|
||||||
|
entrypoint="sh",
|
||||||
|
command='-xc "cp /app/nginx.tmpl {current_dir} && chmod 777 {current_dir}/nginx.tmpl"'.format(
|
||||||
|
current_dir=script_dir
|
||||||
|
),
|
||||||
|
stderr=True,
|
||||||
|
)
|
||||||
|
)
|
||||||
|
yield
|
||||||
|
logging.info("removing nginx.tmpl")
|
||||||
|
os.remove(os.path.join(script_dir, "nginx.tmpl"))
|
||||||
|
|
||||||
|
|
||||||
|
def test_unknown_virtual_host_is_503(nginx_tmpl, docker_compose, nginxproxy):
|
||||||
r = nginxproxy.get("http://unknown.nginx.container.docker/")
|
r = nginxproxy.get("http://unknown.nginx.container.docker/")
|
||||||
assert r.status_code == 503
|
assert r.status_code == 503
|
||||||
|
|
||||||
|
|
||||||
def test_forwards_to_whoami(docker_compose, nginxproxy):
|
def test_forwards_to_whoami(nginx_tmpl, docker_compose, nginxproxy):
|
||||||
r = nginxproxy.get("http://whoami.nginx.container.docker/")
|
r = nginxproxy.get("http://whoami.nginx.container.docker/")
|
||||||
assert r.status_code == 200
|
assert r.status_code == 200
|
||||||
whoami_container = docker_compose.containers.get("whoami")
|
whoami_container = docker_compose.containers.get("whoami")
|
||||||
|
|||||||
@ -14,7 +14,7 @@ services:
|
|||||||
- nginx
|
- nginx
|
||||||
volumes:
|
volumes:
|
||||||
- /var/run/docker.sock:/tmp/docker.sock:ro
|
- /var/run/docker.sock:/tmp/docker.sock:ro
|
||||||
- ../../nginx.tmpl:/etc/docker-gen/templates/nginx.tmpl
|
- ./nginx.tmpl:/etc/docker-gen/templates/nginx.tmpl
|
||||||
|
|
||||||
web:
|
web:
|
||||||
image: web
|
image: web
|
||||||
|
|||||||
@ -1,5 +1,8 @@
|
|||||||
|
import os
|
||||||
import docker
|
import docker
|
||||||
|
import logging
|
||||||
import pytest
|
import pytest
|
||||||
|
import re
|
||||||
from distutils.version import LooseVersion
|
from distutils.version import LooseVersion
|
||||||
|
|
||||||
|
|
||||||
@ -10,12 +13,38 @@ pytestmark = pytest.mark.skipif(
|
|||||||
)
|
)
|
||||||
|
|
||||||
|
|
||||||
def test_unknown_virtual_host_is_503(docker_compose, nginxproxy):
|
@pytest.fixture(scope="module")
|
||||||
|
def nginx_tmpl():
|
||||||
|
"""
|
||||||
|
pytest fixture which extracts the the nginx config template from
|
||||||
|
the nginxproxy/nginx-proxy:test image
|
||||||
|
"""
|
||||||
|
script_dir = os.path.dirname(__file__)
|
||||||
|
logging.info("extracting nginx.tmpl from nginxproxy/nginx-proxy:test")
|
||||||
|
docker_client = docker.from_env()
|
||||||
|
print(
|
||||||
|
docker_client.containers.run(
|
||||||
|
image="nginxproxy/nginx-proxy:test",
|
||||||
|
remove=True,
|
||||||
|
volumes=["{current_dir}:{current_dir}".format(current_dir=script_dir)],
|
||||||
|
entrypoint="sh",
|
||||||
|
command='-xc "cp /app/nginx.tmpl {current_dir} && chmod 777 {current_dir}/nginx.tmpl"'.format(
|
||||||
|
current_dir=script_dir
|
||||||
|
),
|
||||||
|
stderr=True,
|
||||||
|
)
|
||||||
|
)
|
||||||
|
yield
|
||||||
|
logging.info("removing nginx.tmpl")
|
||||||
|
os.remove(os.path.join(script_dir, "nginx.tmpl"))
|
||||||
|
|
||||||
|
|
||||||
|
def test_unknown_virtual_host_is_503(nginx_tmpl, docker_compose, nginxproxy):
|
||||||
r = nginxproxy.get("http://unknown.nginx.container.docker/")
|
r = nginxproxy.get("http://unknown.nginx.container.docker/")
|
||||||
assert r.status_code == 503
|
assert r.status_code == 503
|
||||||
|
|
||||||
|
|
||||||
def test_forwards_to_whoami(docker_compose, nginxproxy):
|
def test_forwards_to_whoami(nginx_tmpl, docker_compose, nginxproxy):
|
||||||
r = nginxproxy.get("http://whoami.nginx.container.docker/")
|
r = nginxproxy.get("http://whoami.nginx.container.docker/")
|
||||||
assert r.status_code == 200
|
assert r.status_code == 200
|
||||||
whoami_container = docker_compose.containers.get("whoami")
|
whoami_container = docker_compose.containers.get("whoami")
|
||||||
|
|||||||
@ -11,7 +11,7 @@ services:
|
|||||||
command: -notify-sighup nginx -watch /etc/docker-gen/templates/nginx.tmpl /etc/nginx/conf.d/default.conf
|
command: -notify-sighup nginx -watch /etc/docker-gen/templates/nginx.tmpl /etc/nginx/conf.d/default.conf
|
||||||
volumes:
|
volumes:
|
||||||
- /var/run/docker.sock:/tmp/docker.sock:ro
|
- /var/run/docker.sock:/tmp/docker.sock:ro
|
||||||
- ../../nginx.tmpl:/etc/docker-gen/templates/nginx.tmpl
|
- ./nginx.tmpl:/etc/docker-gen/templates/nginx.tmpl
|
||||||
- nginx_conf:/etc/nginx/conf.d
|
- nginx_conf:/etc/nginx/conf.d
|
||||||
|
|
||||||
web:
|
web:
|
||||||
|
|||||||
@ -1,71 +0,0 @@
|
|||||||
Certificate:
|
|
||||||
Data:
|
|
||||||
Version: 3 (0x2)
|
|
||||||
Serial Number: 4096 (0x1000)
|
|
||||||
Signature Algorithm: sha256WithRSAEncryption
|
|
||||||
Issuer: O=nginx-proxy test suite, CN=www.nginx-proxy.tld
|
|
||||||
Validity
|
|
||||||
Not Before: Feb 7 21:54:16 2023 GMT
|
|
||||||
Not After : Jun 25 21:54:16 2050 GMT
|
|
||||||
Subject: CN=http-only.nginx-proxy.test
|
|
||||||
Subject Public Key Info:
|
|
||||||
Public Key Algorithm: rsaEncryption
|
|
||||||
RSA Public-Key: (2048 bit)
|
|
||||||
Modulus:
|
|
||||||
00:b4:62:61:07:54:2e:6d:55:83:2d:24:b7:e2:15:
|
|
||||||
34:13:bd:79:21:e9:10:75:3f:4c:f8:ba:60:29:87:
|
|
||||||
e5:8e:2a:1e:fd:33:51:5a:8a:3a:6f:60:ff:24:f1:
|
|
||||||
1b:27:30:8c:ac:43:04:b7:79:cb:7a:ec:c6:08:a4:
|
|
||||||
a0:15:b0:0f:ee:6b:15:84:24:11:bc:85:2b:48:06:
|
|
||||||
04:0a:58:bb:8c:e8:4d:48:f5:06:c5:91:fe:5d:99:
|
|
||||||
0a:29:31:8a:f1:9b:0c:e0:39:75:a1:06:9b:d4:f5:
|
|
||||||
06:74:8f:46:5e:64:ba:2f:d0:3d:7c:3d:30:03:e9:
|
|
||||||
7c:35:17:69:04:f6:2e:29:d4:93:d6:d6:d2:6c:04:
|
|
||||||
38:06:21:06:05:30:8a:b9:9d:05:8d:12:6e:48:39:
|
|
||||||
bb:f6:93:4f:ba:a5:84:c7:96:2f:be:92:25:e9:d0:
|
|
||||||
95:2a:d9:23:8a:b3:28:0b:b6:19:1c:3b:be:a2:91:
|
|
||||||
70:44:a8:77:18:94:4b:df:61:f4:5c:c9:78:76:34:
|
|
||||||
b5:87:0f:c0:92:04:26:b6:ca:62:cd:9b:5d:eb:bf:
|
|
||||||
10:ac:df:af:72:5f:af:09:38:b1:dc:e1:3d:13:db:
|
|
||||||
a0:ac:b7:2e:ca:39:5c:4c:f1:1e:81:a8:b4:44:a2:
|
|
||||||
72:d5:3b:c0:71:cc:dc:16:0d:fa:38:96:44:b3:00:
|
|
||||||
d6:65
|
|
||||||
Exponent: 65537 (0x10001)
|
|
||||||
X509v3 extensions:
|
|
||||||
X509v3 Subject Alternative Name:
|
|
||||||
DNS:http-only.nginx-proxy.test
|
|
||||||
Signature Algorithm: sha256WithRSAEncryption
|
|
||||||
3b:54:95:48:4d:f6:93:38:42:40:02:ab:b7:17:3b:50:3b:ca:
|
|
||||||
c7:12:69:b0:da:cb:d7:3e:0e:1f:bf:a2:59:c7:fe:c2:5c:43:
|
|
||||||
84:92:b9:3a:be:8f:7e:2e:81:3c:ed:f3:a9:77:21:c2:35:f1:
|
|
||||||
da:cf:3a:1e:e2:ee:a2:ce:72:55:97:87:0e:ad:59:61:f7:75:
|
|
||||||
46:c0:2b:d4:88:b7:36:97:11:fb:5e:28:89:e9:2a:92:f1:15:
|
|
||||||
f1:43:8e:c1:38:85:8d:3a:26:7d:25:72:93:17:96:8d:5a:ed:
|
|
||||||
e8:73:3a:d5:8d:80:f2:af:38:84:ff:85:2e:d1:36:7d:2e:e1:
|
|
||||||
f0:2c:d8:15:5f:fc:c5:70:5d:25:6a:22:f3:2a:cd:0f:25:ad:
|
|
||||||
d4:93:d3:9a:3e:50:bc:da:a5:6c:86:ea:1d:d9:b9:c5:90:db:
|
|
||||||
f5:02:c8:c9:77:5c:ef:77:fe:74:60:41:33:d9:3c:a2:e1:73:
|
|
||||||
aa:14:18:5d:36:58:c8:41:63:4c:59:0e:4b:3d:c5:65:5a:01:
|
|
||||||
b0:16:50:0f:d0:4f:0d:ca:97:f6:11:47:06:6b:b1:ae:bb:26:
|
|
||||||
30:34:8b:7a:91:5d:8a:22:c7:f9:05:0d:bb:a5:b7:60:c0:20:
|
|
||||||
ce:d0:0e:c0:66:b3:e7:c4:61:ec:c5:40:e6:52:11:41:c3:11:
|
|
||||||
18:04:c7:1e
|
|
||||||
-----BEGIN CERTIFICATE-----
|
|
||||||
MIIDCzCCAfOgAwIBAgICEAAwDQYJKoZIhvcNAQELBQAwPzEfMB0GA1UECgwWbmdp
|
|
||||||
bngtcHJveHkgdGVzdCBzdWl0ZTEcMBoGA1UEAwwTd3d3Lm5naW54LXByb3h5LnRs
|
|
||||||
ZDAgFw0yMzAyMDcyMTU0MTZaGA8yMDUwMDYyNTIxNTQxNlowJTEjMCEGA1UEAwwa
|
|
||||||
aHR0cC1vbmx5Lm5naW54LXByb3h5LnRlc3QwggEiMA0GCSqGSIb3DQEBAQUAA4IB
|
|
||||||
DwAwggEKAoIBAQC0YmEHVC5tVYMtJLfiFTQTvXkh6RB1P0z4umAph+WOKh79M1Fa
|
|
||||||
ijpvYP8k8RsnMIysQwS3ect67MYIpKAVsA/uaxWEJBG8hStIBgQKWLuM6E1I9QbF
|
|
||||||
kf5dmQopMYrxmwzgOXWhBpvU9QZ0j0ZeZLov0D18PTAD6Xw1F2kE9i4p1JPW1tJs
|
|
||||||
BDgGIQYFMIq5nQWNEm5IObv2k0+6pYTHli++kiXp0JUq2SOKsygLthkcO76ikXBE
|
|
||||||
qHcYlEvfYfRcyXh2NLWHD8CSBCa2ymLNm13rvxCs369yX68JOLHc4T0T26Csty7K
|
|
||||||
OVxM8R6BqLREonLVO8BxzNwWDfo4lkSzANZlAgMBAAGjKTAnMCUGA1UdEQQeMByC
|
|
||||||
Gmh0dHAtb25seS5uZ2lueC1wcm94eS50ZXN0MA0GCSqGSIb3DQEBCwUAA4IBAQA7
|
|
||||||
VJVITfaTOEJAAqu3FztQO8rHEmmw2svXPg4fv6JZx/7CXEOEkrk6vo9+LoE87fOp
|
|
||||||
dyHCNfHazzoe4u6iznJVl4cOrVlh93VGwCvUiLc2lxH7XiiJ6SqS8RXxQ47BOIWN
|
|
||||||
OiZ9JXKTF5aNWu3oczrVjYDyrziE/4Uu0TZ9LuHwLNgVX/zFcF0laiLzKs0PJa3U
|
|
||||||
k9OaPlC82qVshuod2bnFkNv1AsjJd1zvd/50YEEz2Tyi4XOqFBhdNljIQWNMWQ5L
|
|
||||||
PcVlWgGwFlAP0E8Nypf2EUcGa7GuuyYwNIt6kV2KIsf5BQ27pbdgwCDO0A7AZrPn
|
|
||||||
xGHsxUDmUhFBwxEYBMce
|
|
||||||
-----END CERTIFICATE-----
|
|
||||||
@ -1,27 +0,0 @@
|
|||||||
-----BEGIN RSA PRIVATE KEY-----
|
|
||||||
MIIEpAIBAAKCAQEAtGJhB1QubVWDLSS34hU0E715IekQdT9M+LpgKYfljioe/TNR
|
|
||||||
Woo6b2D/JPEbJzCMrEMEt3nLeuzGCKSgFbAP7msVhCQRvIUrSAYECli7jOhNSPUG
|
|
||||||
xZH+XZkKKTGK8ZsM4Dl1oQab1PUGdI9GXmS6L9A9fD0wA+l8NRdpBPYuKdST1tbS
|
|
||||||
bAQ4BiEGBTCKuZ0FjRJuSDm79pNPuqWEx5YvvpIl6dCVKtkjirMoC7YZHDu+opFw
|
|
||||||
RKh3GJRL32H0XMl4djS1hw/AkgQmtspizZtd678QrN+vcl+vCTix3OE9E9ugrLcu
|
|
||||||
yjlcTPEegai0RKJy1TvAcczcFg36OJZEswDWZQIDAQABAoIBAAfDA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c973yf2vwEnw0R7Dlutt6dc9VgxNWj4GE0GMe
|
|
||||||
Tiao7Uom7Tf4p7wC9+r9rI/zOz2f8OxRIK18wtbShWfR5fx1dCWUXmGb3+jUse1O
|
|
||||||
4Qk2FcECgYAvSvGFoJb8tuHFEYYHBbjficmvTUsrTE+EhxPqWKFhKfF19fFFIupy
|
|
||||||
XBCrN6nwrh+/YMxZXeIRbbTTf814cOO7PjLeNhnfhJZkaJq1HzbYe3bOurna3qrm
|
|
||||||
Ra3xiM8Ld2PyGnZPXf8+AWhMhuPkLX1KFVTCAxwCpmTZCHtiGCmXMA==
|
|
||||||
-----END RSA PRIVATE KEY-----
|
|
||||||
@ -1,71 +0,0 @@
|
|||||||
Certificate:
|
|
||||||
Data:
|
|
||||||
Version: 3 (0x2)
|
|
||||||
Serial Number: 4096 (0x1000)
|
|
||||||
Signature Algorithm: sha256WithRSAEncryption
|
|
||||||
Issuer: O=nginx-proxy test suite, CN=www.nginx-proxy.tld
|
|
||||||
Validity
|
|
||||||
Not Before: Feb 7 21:53:19 2023 GMT
|
|
||||||
Not After : Jun 25 21:53:19 2050 GMT
|
|
||||||
Subject: CN=https-and-http.nginx-proxy.test
|
|
||||||
Subject Public Key Info:
|
|
||||||
Public Key Algorithm: rsaEncryption
|
|
||||||
RSA Public-Key: (2048 bit)
|
|
||||||
Modulus:
|
|
||||||
00:b7:97:85:d1:7f:6b:50:29:f3:87:b7:4e:f5:25:
|
|
||||||
40:6a:d8:fa:a1:63:3c:4a:2e:68:4a:c6:8b:38:df:
|
|
||||||
07:81:d0:08:9d:fc:17:f5:37:28:7f:31:e6:f3:81:
|
|
||||||
28:4e:22:b6:bd:a2:4e:f2:2f:e5:0f:dd:55:3c:e1:
|
|
||||||
04:84:4c:45:1b:1a:ae:b7:f0:2a:da:43:05:71:91:
|
|
||||||
92:b8:d1:49:fe:80:0a:53:b9:66:da:54:60:9a:fc:
|
|
||||||
e1:b2:e8:28:48:7f:96:94:3c:92:a3:b2:37:f6:7a:
|
|
||||||
c2:de:0b:12:f0:ae:4e:92:fe:2d:c1:b2:95:28:1f:
|
|
||||||
88:8d:79:99:81:19:ae:22:a4:95:f5:9f:db:25:8e:
|
|
||||||
1d:cf:43:cd:6f:85:93:5f:79:ee:f8:f3:d4:82:e1:
|
|
||||||
e9:4d:c9:ad:ae:5b:92:43:3a:3c:71:51:70:f7:3e:
|
|
||||||
bd:1b:24:52:6a:a3:cf:54:72:57:ed:fe:72:ea:96:
|
|
||||||
9b:5a:02:02:a7:df:85:b7:68:ae:1e:07:77:9f:59:
|
|
||||||
a5:a0:8b:28:c2:c8:b7:bb:8a:42:50:df:05:73:bf:
|
|
||||||
9c:55:13:b5:82:79:77:40:57:a4:8f:88:a5:71:50:
|
|
||||||
d7:70:b0:4d:0c:d9:86:b3:9b:db:8a:20:bd:19:68:
|
|
||||||
10:52:2d:53:ba:0e:2e:1c:ad:80:54:bb:b6:c9:ab:
|
|
||||||
11:39
|
|
||||||
Exponent: 65537 (0x10001)
|
|
||||||
X509v3 extensions:
|
|
||||||
X509v3 Subject Alternative Name:
|
|
||||||
DNS:https-and-http.nginx-proxy.test
|
|
||||||
Signature Algorithm: sha256WithRSAEncryption
|
|
||||||
2c:f3:e5:47:3f:8e:5a:28:b1:df:e5:95:50:85:6f:27:2f:a6:
|
|
||||||
8d:f1:5e:cf:df:e2:52:66:97:61:36:59:81:26:25:19:99:c9:
|
|
||||||
93:e5:85:cb:ca:69:af:4b:21:a3:d2:7a:bf:b5:5e:2d:42:fb:
|
|
||||||
99:f8:22:58:e5:bf:79:b8:8a:74:7e:c6:94:14:d9:f2:27:63:
|
|
||||||
b6:e5:74:21:5b:59:fb:f6:c8:a9:28:fb:60:f7:5e:bd:c2:e6:
|
|
||||||
74:24:14:96:61:95:6c:c2:66:b4:52:25:a1:85:5a:97:e5:68:
|
|
||||||
5c:62:cf:69:3b:b0:a9:56:d8:e3:5f:74:dc:84:18:d5:3e:4f:
|
|
||||||
c9:35:39:26:88:dc:9b:80:d9:40:e1:4f:09:27:8d:d2:89:55:
|
|
||||||
30:91:02:86:35:04:95:1e:1d:58:14:5b:c6:e0:2e:a7:bf:a8:
|
|
||||||
f6:2b:76:8a:4e:71:79:bc:c0:04:cd:db:81:73:46:ce:68:ed:
|
|
||||||
25:b0:0e:42:8d:96:64:77:3b:f4:9d:1a:c9:f6:78:4c:56:4f:
|
|
||||||
92:17:29:3d:80:50:71:77:4b:a8:29:c2:12:fc:ad:0a:37:81:
|
|
||||||
38:4c:fb:54:99:4d:12:5f:98:dc:d1:a9:7b:08:45:c4:6f:7e:
|
|
||||||
fe:00:e0:db:79:fe:d1:28:e3:8e:82:d1:fb:bc:0a:c4:42:93:
|
|
||||||
c9:5e:eb:ba
|
|
||||||
-----BEGIN CERTIFICATE-----
|
|
||||||
MIIDFTCCAf2gAwIBAgICEAAwDQYJKoZIhvcNAQELBQAwPzEfMB0GA1UECgwWbmdp
|
|
||||||
bngtcHJveHkgdGVzdCBzdWl0ZTEcMBoGA1UEAwwTd3d3Lm5naW54LXByb3h5LnRs
|
|
||||||
ZDAgFw0yMzAyMDcyMTUzMTlaGA8yMDUwMDYyNTIxNTMxOVowKjEoMCYGA1UEAwwf
|
|
||||||
aHR0cHMtYW5kLWh0dHAubmdpbngtcHJveHkudGVzdDCCASIwDQYJKoZIhvcNAQEB
|
|
||||||
BQADggEPADCCAQoCggEBALeXhdF/a1Ap84e3TvUlQGrY+qFjPEouaErGizjfB4HQ
|
|
||||||
CJ38F/U3KH8x5vOBKE4itr2iTvIv5Q/dVTzhBIRMRRsarrfwKtpDBXGRkrjRSf6A
|
|
||||||
ClO5ZtpUYJr84bLoKEh/lpQ8kqOyN/Z6wt4LEvCuTpL+LcGylSgfiI15mYEZriKk
|
|
||||||
lfWf2yWOHc9DzW+Fk1957vjz1ILh6U3Jra5bkkM6PHFRcPc+vRskUmqjz1RyV+3+
|
|
||||||
cuqWm1oCAqffhbdorh4Hd59ZpaCLKMLIt7uKQlDfBXO/nFUTtYJ5d0BXpI+IpXFQ
|
|
||||||
13CwTQzZhrOb24ogvRloEFItU7oOLhytgFS7tsmrETkCAwEAAaMuMCwwKgYDVR0R
|
|
||||||
BCMwIYIfaHR0cHMtYW5kLWh0dHAubmdpbngtcHJveHkudGVzdDANBgkqhkiG9w0B
|
|
||||||
AQsFAAOCAQEALPPlRz+OWiix3+WVUIVvJy+mjfFez9/iUmaXYTZZgSYlGZnJk+WF
|
|
||||||
y8ppr0sho9J6v7VeLUL7mfgiWOW/ebiKdH7GlBTZ8idjtuV0IVtZ+/bIqSj7YPde
|
|
||||||
vcLmdCQUlmGVbMJmtFIloYVal+VoXGLPaTuwqVbY41903IQY1T5PyTU5Jojcm4DZ
|
|
||||||
QOFPCSeN0olVMJEChjUElR4dWBRbxuAup7+o9it2ik5xebzABM3bgXNGzmjtJbAO
|
|
||||||
Qo2WZHc79J0ayfZ4TFZPkhcpPYBQcXdLqCnCEvytCjeBOEz7VJlNEl+Y3NGpewhF
|
|
||||||
xG9+/gDg23n+0SjjjoLR+7wKxEKTyV7rug==
|
|
||||||
-----END CERTIFICATE-----
|
|
||||||
@ -1,27 +0,0 @@
|
|||||||
-----BEGIN RSA PRIVATE KEY-----
|
|
||||||
MIIEpAIBAAKCAQEAt5eF0X9rUCnzh7dO9SVAatj6oWM8Si5oSsaLON8HgdAInfwX
|
|
||||||
9TcofzHm84EoTiK2vaJO8i/lD91VPOEEhExFGxqut/Aq2kMFcZGSuNFJ/oAKU7lm
|
|
||||||
2lRgmvzhsugoSH+WlDySo7I39nrC3gsS8K5Okv4twbKVKB+IjXmZgRmuIqSV9Z/b
|
|
||||||
JY4dz0PNb4WTX3nu+PPUguHpTcmtrluSQzo8cVFw9z69GyRSaqPPVHJX7f5y6pab
|
|
||||||
WgICp9+Ft2iuHgd3n1mloIsowsi3u4pCUN8Fc7+cVRO1gnl3QFekj4ilcVDXcLBN
|
|
||||||
DNmGs5vbiiC9GWgQUi1Tug4uHK2AVLu2yasROQIDAQABAoIBACT4KSVHoEd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squWxsJtRoibgM7IucsTml+b8v2j7hstP3IqCjn+9Wr
|
|
||||||
swDG28WTyXNvu31JgP04dLaRoVIAlOdsofym6OiLNvozO0M3VsziXMjZnVlK8zfP
|
|
||||||
dORkQQKBgQDXAJEJPygxVA+bF104dzCMWGmU7K8ShEWC5eOdKK4KWf9bNDpY6M6c
|
|
||||||
i6zga/xBbj7e3Bxqprpp8Wy2gIsnYiVo4V9EQethbLdomPxOpBMNMARw81rL1CpO
|
|
||||||
jbHB7bIDcKs2tQoZEXUW86ZxC8sdaDaWTJTfUO0RpJow6ZO3yvxVIQ==
|
|
||||||
-----END RSA PRIVATE KEY-----
|
|
||||||
@ -1,71 +0,0 @@
|
|||||||
Certificate:
|
|
||||||
Data:
|
|
||||||
Version: 3 (0x2)
|
|
||||||
Serial Number: 4096 (0x1000)
|
|
||||||
Signature Algorithm: sha256WithRSAEncryption
|
|
||||||
Issuer: O=nginx-proxy test suite, CN=www.nginx-proxy.tld
|
|
||||||
Validity
|
|
||||||
Not Before: Feb 7 21:53:49 2023 GMT
|
|
||||||
Not After : Jun 25 21:53:49 2050 GMT
|
|
||||||
Subject: CN=https-only.nginx-proxy.test
|
|
||||||
Subject Public Key Info:
|
|
||||||
Public Key Algorithm: rsaEncryption
|
|
||||||
RSA Public-Key: (2048 bit)
|
|
||||||
Modulus:
|
|
||||||
00:d9:87:48:02:85:f4:5f:0d:90:7e:4c:4f:13:89:
|
|
||||||
41:ca:41:15:c2:6f:fd:a8:c7:17:83:c6:dd:8c:fe:
|
|
||||||
19:a4:b2:6b:0b:35:4f:b4:3d:7c:40:0a:04:33:2a:
|
|
||||||
fd:10:72:f7:63:63:99:5b:3d:ec:78:ee:c6:4d:c8:
|
|
||||||
0e:4c:be:f2:3f:e3:02:74:57:9a:c1:fe:15:95:63:
|
|
||||||
4e:e7:2c:eb:70:f2:6b:c8:ba:01:a2:ca:a1:c7:76:
|
|
||||||
ff:38:e4:c2:b0:66:fc:85:d2:af:0f:22:81:d4:82:
|
|
||||||
eb:d5:b0:e6:69:14:37:dd:8d:ad:29:ce:93:68:5a:
|
|
||||||
ce:f4:77:76:6f:78:13:b6:c8:2f:fe:e0:b6:7e:fb:
|
|
||||||
29:16:be:e2:f5:45:3b:39:5b:52:dc:26:b7:ca:0c:
|
|
||||||
b6:1c:fc:a8:38:0b:dd:c1:f4:04:9b:2d:38:c9:a5:
|
|
||||||
2d:3e:f1:42:88:53:a2:3b:17:cf:d5:3c:2b:d6:6a:
|
|
||||||
7f:6f:05:8d:c5:b7:5d:64:1e:83:1b:e7:ec:80:3d:
|
|
||||||
6d:34:c1:66:b2:e6:5d:d9:a7:6e:46:75:14:bf:10:
|
|
||||||
16:c5:fc:47:8e:63:fa:e5:b4:bd:f2:b9:e0:cb:ea:
|
|
||||||
75:f9:68:ee:7d:8f:ea:8f:1a:9f:34:27:7a:4a:9f:
|
|
||||||
85:fd:3e:17:a7:96:c3:d0:4e:50:a2:a2:e0:45:92:
|
|
||||||
d0:b5
|
|
||||||
Exponent: 65537 (0x10001)
|
|
||||||
X509v3 extensions:
|
|
||||||
X509v3 Subject Alternative Name:
|
|
||||||
DNS:https-only.nginx-proxy.test
|
|
||||||
Signature Algorithm: sha256WithRSAEncryption
|
|
||||||
8a:52:46:42:a9:74:18:6a:52:90:ef:a4:e9:c5:54:d5:97:3a:
|
|
||||||
ff:8b:c2:76:4f:9e:47:aa:e1:ea:e5:b9:af:9d:33:e3:85:17:
|
|
||||||
54:7d:32:bd:ac:90:3f:5c:d2:a1:42:17:52:2b:b1:83:e5:c3:
|
|
||||||
bf:81:f0:e7:38:e2:88:67:7b:d8:59:fe:f9:94:99:ba:be:f4:
|
|
||||||
3c:24:b2:c7:9e:f0:98:21:c6:2d:c2:e8:f3:67:bd:62:00:aa:
|
|
||||||
ce:34:fa:b4:53:6d:c1:09:5e:55:bd:43:aa:86:c6:f8:c5:83:
|
|
||||||
46:3a:49:12:a2:ec:30:36:0c:99:44:74:09:9d:cc:4b:98:1f:
|
|
||||||
7e:c9:9b:68:a0:f8:1e:00:14:d0:da:2a:bf:c8:ca:a8:1c:10:
|
|
||||||
b5:68:a2:f1:41:93:0c:f3:3f:c0:c6:53:3c:8d:a7:dd:a5:7b:
|
|
||||||
35:cc:44:e0:5b:6d:c5:cb:33:6f:c1:43:7e:06:df:21:99:11:
|
|
||||||
b3:91:41:b4:5e:f0:37:1e:8e:e5:73:85:dc:4a:21:d5:41:f9:
|
|
||||||
4e:b8:f5:ed:21:93:09:91:c2:8c:6b:04:a4:84:ab:3a:fe:35:
|
|
||||||
64:fa:6b:a7:8d:40:a6:64:89:30:84:ac:28:99:5a:01:79:77:
|
|
||||||
c0:df:88:da:a9:75:5f:c4:51:ae:a8:45:7b:d2:e1:a2:81:29:
|
|
||||||
60:cd:7b:cd
|
|
||||||
-----BEGIN CERTIFICATE-----
|
|
||||||
MIIDDTCCAfWgAwIBAgICEAAwDQYJKoZIhvcNAQELBQAwPzEfMB0GA1UECgwWbmdp
|
|
||||||
bngtcHJveHkgdGVzdCBzdWl0ZTEcMBoGA1UEAwwTd3d3Lm5naW54LXByb3h5LnRs
|
|
||||||
ZDAgFw0yMzAyMDcyMTUzNDlaGA8yMDUwMDYyNTIxNTM0OVowJjEkMCIGA1UEAwwb
|
|
||||||
aHR0cHMtb25seS5uZ2lueC1wcm94eS50ZXN0MIIBIjANBgkqhkiG9w0BAQEFAAOC
|
|
||||||
AQ8AMIIBCgKCAQEA2YdIAoX0Xw2QfkxPE4lBykEVwm/9qMcXg8bdjP4ZpLJrCzVP
|
|
||||||
tD18QAoEMyr9EHL3Y2OZWz3seO7GTcgOTL7yP+MCdFeawf4VlWNO5yzrcPJryLoB
|
|
||||||
osqhx3b/OOTCsGb8hdKvDyKB1ILr1bDmaRQ33Y2tKc6TaFrO9Hd2b3gTtsgv/uC2
|
|
||||||
fvspFr7i9UU7OVtS3Ca3ygy2HPyoOAvdwfQEmy04yaUtPvFCiFOiOxfP1Twr1mp/
|
|
||||||
bwWNxbddZB6DG+fsgD1tNMFmsuZd2aduRnUUvxAWxfxHjmP65bS98rngy+p1+Wju
|
|
||||||
fY/qjxqfNCd6Sp+F/T4Xp5bD0E5QoqLgRZLQtQIDAQABoyowKDAmBgNVHREEHzAd
|
|
||||||
ghtodHRwcy1vbmx5Lm5naW54LXByb3h5LnRlc3QwDQYJKoZIhvcNAQELBQADggEB
|
|
||||||
AIpSRkKpdBhqUpDvpOnFVNWXOv+LwnZPnkeq4erlua+dM+OFF1R9Mr2skD9c0qFC
|
|
||||||
F1IrsYPlw7+B8Oc44ohne9hZ/vmUmbq+9Dwkssee8Jghxi3C6PNnvWIAqs40+rRT
|
|
||||||
bcEJXlW9Q6qGxvjFg0Y6SRKi7DA2DJlEdAmdzEuYH37Jm2ig+B4AFNDaKr/Iyqgc
|
|
||||||
ELVoovFBkwzzP8DGUzyNp92lezXMROBbbcXLM2/BQ34G3yGZEbORQbRe8DcejuVz
|
|
||||||
hdxKIdVB+U649e0hkwmRwoxrBKSEqzr+NWT6a6eNQKZkiTCErCiZWgF5d8DfiNqp
|
|
||||||
dV/EUa6oRXvS4aKBKWDNe80=
|
|
||||||
-----END CERTIFICATE-----
|
|
||||||
@ -1,27 +0,0 @@
|
|||||||
-----BEGIN RSA PRIVATE KEY-----
|
|
||||||
MIIEowIBAAKCAQEA2YdIAoX0Xw2QfkxPE4lBykEVwm/9qMcXg8bdjP4ZpLJrCzVP
|
|
||||||
tD18QAoEMyr9EHL3Y2OZWz3seO7GTcgOTL7yP+MCdFeawf4VlWNO5yzrcPJryLoB
|
|
||||||
osqhx3b/OOTCsGb8hdKvDyKB1ILr1bDmaRQ33Y2tKc6TaFrO9Hd2b3gTtsgv/uC2
|
|
||||||
fvspFr7i9UU7OVtS3Ca3ygy2HPyoOAvdwfQEmy04yaUtPvFCiFOiOxfP1Twr1mp/
|
|
||||||
bwWNxbddZB6DG+fsgD1tNMFmsuZd2aduRnUUvxAWxfxHjmP65bS98rngy+p1+Wju
|
|
||||||
fY/qjxqfNCd6Sp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yRf+/9IbiRDI
|
|
||||||
pVL/s8FmVPHw7jIHhHwuo7lCImnz4LGy5C6oOnIizIRAy/04Ty0Hd8ri5YmPlbHI
|
|
||||||
8A8gbMiB7zeNU1zlXP5jzFPyo2tMhLyGH5gnTdwOtfnPD/dCPe45ZJYyISIOg3O0
|
|
||||||
3peMBwKBgH20cskAOCNclfoG+Nis52h8FqmDlflJ8waUarvk26JhO1e009kOytw8
|
|
||||||
x/qSuttpGtTG+4fdc2wJvFNczr4h9ZlftBdgZXj8PKgRpcIe8q97Xg8PUj+Xfu/t
|
|
||||||
vD/QV+tVcGoAMsQq4NeFxiTbPfwVyXdYFT1XVCu6JEdLL+gpWh5W
|
|
||||||
-----END RSA PRIVATE KEY-----
|
|
||||||
@ -1,36 +0,0 @@
|
|||||||
services:
|
|
||||||
sut:
|
|
||||||
image: nginxproxy/nginx-proxy:test
|
|
||||||
volumes:
|
|
||||||
- /var/run/docker.sock:/tmp/docker.sock:ro
|
|
||||||
- ./nodefault.certs:/etc/nginx/certs:ro
|
|
||||||
https-and-http:
|
|
||||||
image: web
|
|
||||||
expose:
|
|
||||||
- "81"
|
|
||||||
environment:
|
|
||||||
WEB_PORTS: "81"
|
|
||||||
VIRTUAL_HOST: https-and-http.nginx-proxy.test
|
|
||||||
https-only:
|
|
||||||
image: web
|
|
||||||
expose:
|
|
||||||
- "82"
|
|
||||||
environment:
|
|
||||||
WEB_PORTS: "82"
|
|
||||||
VIRTUAL_HOST: https-only.nginx-proxy.test
|
|
||||||
HTTPS_METHOD: nohttp
|
|
||||||
http-only:
|
|
||||||
image: web
|
|
||||||
expose:
|
|
||||||
- "83"
|
|
||||||
environment:
|
|
||||||
WEB_PORTS: "83"
|
|
||||||
VIRTUAL_HOST: http-only.nginx-proxy.test
|
|
||||||
HTTPS_METHOD: nohttps
|
|
||||||
missing-cert:
|
|
||||||
image: web
|
|
||||||
expose:
|
|
||||||
- "84"
|
|
||||||
environment:
|
|
||||||
WEB_PORTS: "84"
|
|
||||||
VIRTUAL_HOST: missing-cert.nginx-proxy.test
|
|
||||||
@ -1,16 +0,0 @@
|
|||||||
services:
|
|
||||||
sut:
|
|
||||||
image: nginxproxy/nginx-proxy:test
|
|
||||||
volumes:
|
|
||||||
- /var/run/docker.sock:/tmp/docker.sock:ro
|
|
||||||
- ./withdefault.certs:/etc/nginx/certs:ro
|
|
||||||
environment:
|
|
||||||
HTTPS_METHOD: redirect
|
|
||||||
https-only:
|
|
||||||
image: web
|
|
||||||
expose:
|
|
||||||
- "82"
|
|
||||||
environment:
|
|
||||||
WEB_PORTS: "82"
|
|
||||||
HTTPS_METHOD: nohttp
|
|
||||||
VIRTUAL_HOST: https-only.nginx-proxy.test
|
|
||||||
@ -1,22 +0,0 @@
|
|||||||
services:
|
|
||||||
sut:
|
|
||||||
image: nginxproxy/nginx-proxy:test
|
|
||||||
volumes:
|
|
||||||
- /var/run/docker.sock:/tmp/docker.sock:ro
|
|
||||||
- ./withdefault.certs:/etc/nginx/certs:ro
|
|
||||||
environment:
|
|
||||||
HTTPS_METHOD: nohttp
|
|
||||||
https-only:
|
|
||||||
image: web
|
|
||||||
expose:
|
|
||||||
- "82"
|
|
||||||
environment:
|
|
||||||
WEB_PORTS: "82"
|
|
||||||
VIRTUAL_HOST: https-only.nginx-proxy.test
|
|
||||||
missing-cert:
|
|
||||||
image: web
|
|
||||||
expose:
|
|
||||||
- "84"
|
|
||||||
environment:
|
|
||||||
WEB_PORTS: "84"
|
|
||||||
VIRTUAL_HOST: missing-cert.nginx-proxy.test
|
|
||||||
@ -1,15 +0,0 @@
|
|||||||
services:
|
|
||||||
sut:
|
|
||||||
image: nginxproxy/nginx-proxy:test
|
|
||||||
volumes:
|
|
||||||
- /var/run/docker.sock:/tmp/docker.sock:ro
|
|
||||||
- ./withdefault.certs:/etc/nginx/certs:ro
|
|
||||||
environment:
|
|
||||||
HTTPS_METHOD: nohttp
|
|
||||||
https-only:
|
|
||||||
image: web
|
|
||||||
expose:
|
|
||||||
- "82"
|
|
||||||
environment:
|
|
||||||
WEB_PORTS: "82"
|
|
||||||
VIRTUAL_HOST: https-only.nginx-proxy.test
|
|
||||||
@ -1,15 +0,0 @@
|
|||||||
services:
|
|
||||||
sut:
|
|
||||||
image: nginxproxy/nginx-proxy:test
|
|
||||||
volumes:
|
|
||||||
- /var/run/docker.sock:/tmp/docker.sock:ro
|
|
||||||
environment:
|
|
||||||
HTTPS_METHOD: redirect
|
|
||||||
http-only:
|
|
||||||
image: web
|
|
||||||
expose:
|
|
||||||
- "83"
|
|
||||||
environment:
|
|
||||||
WEB_PORTS: "83"
|
|
||||||
HTTPS_METHOD: nohttps
|
|
||||||
VIRTUAL_HOST: http-only.nginx-proxy.test
|
|
||||||
@ -1,14 +0,0 @@
|
|||||||
services:
|
|
||||||
sut:
|
|
||||||
image: nginxproxy/nginx-proxy:test
|
|
||||||
volumes:
|
|
||||||
- /var/run/docker.sock:/tmp/docker.sock:ro
|
|
||||||
environment:
|
|
||||||
HTTPS_METHOD: nohttps
|
|
||||||
http-only:
|
|
||||||
image: web
|
|
||||||
expose:
|
|
||||||
- "83"
|
|
||||||
environment:
|
|
||||||
WEB_PORTS: "83"
|
|
||||||
VIRTUAL_HOST: http-only.nginx-proxy.test
|
|
||||||
@ -1,70 +0,0 @@
|
|||||||
Certificate:
|
|
||||||
Data:
|
|
||||||
Version: 3 (0x2)
|
|
||||||
Serial Number: 4096 (0x1000)
|
|
||||||
Signature Algorithm: sha256WithRSAEncryption
|
|
||||||
Issuer: O=nginx-proxy test suite, CN=www.nginx-proxy.tld
|
|
||||||
Validity
|
|
||||||
Not Before: Feb 9 04:02:23 2023 GMT
|
|
||||||
Not After : Jun 27 04:02:23 2050 GMT
|
|
||||||
Subject: CN=*.nginx-proxy.test
|
|
||||||
Subject Public Key Info:
|
|
||||||
Public Key Algorithm: rsaEncryption
|
|
||||||
RSA Public-Key: (2048 bit)
|
|
||||||
Modulus:
|
|
||||||
00:db:bd:54:de:01:7e:82:4e:c0:f1:5d:12:fd:3a:
|
|
||||||
fb:21:19:4d:44:25:47:ea:ad:d8:11:5c:d1:65:88:
|
|
||||||
af:49:fc:8e:4b:c3:01:c1:0d:6d:22:67:bd:31:66:
|
|
||||||
9f:4a:50:17:9e:47:b3:3b:b3:21:73:1f:81:55:73:
|
|
||||||
52:47:9b:fb:85:6b:e8:d8:09:cc:e1:7d:1c:14:03:
|
|
||||||
1c:ae:84:b4:5b:e5:e5:c7:71:fc:1f:74:33:4f:ae:
|
|
||||||
f7:8d:21:1f:55:8d:93:c7:84:4d:93:01:a1:1c:37:
|
|
||||||
ae:85:5c:70:2c:21:ec:87:35:c3:86:d3:b3:0f:9a:
|
|
||||||
b0:9d:8a:cd:0e:49:e8:99:c5:4c:50:bd:a8:6e:a7:
|
|
||||||
01:3e:a7:dc:cf:c3:48:37:8e:c6:8a:89:b0:41:01:
|
|
||||||
58:ee:45:94:fa:90:eb:df:c8:0e:b7:dd:79:75:13:
|
|
||||||
1e:07:69:ee:54:47:92:18:9d:e0:a9:ee:4e:22:d1:
|
|
||||||
f4:a2:4d:a1:47:ed:9b:35:2a:70:cc:66:fb:3e:f0:
|
|
||||||
49:f7:ee:62:2a:27:a1:d3:52:7b:ff:e9:12:d9:5b:
|
|
||||||
6b:f6:18:bf:9c:9d:5f:00:29:d2:54:b5:f8:a4:a2:
|
|
||||||
9b:3f:fe:a6:ed:14:ae:a0:fe:13:33:18:33:17:a9:
|
|
||||||
8b:fe:fc:75:65:0c:fb:c2:d1:1e:81:ca:43:89:bd:
|
|
||||||
78:dd
|
|
||||||
Exponent: 65537 (0x10001)
|
|
||||||
X509v3 extensions:
|
|
||||||
X509v3 Subject Alternative Name:
|
|
||||||
DNS:*.nginx-proxy.test
|
|
||||||
Signature Algorithm: sha256WithRSAEncryption
|
|
||||||
43:a7:1f:4b:ec:ff:1d:70:c7:f8:6e:eb:fd:15:25:27:b2:54:
|
|
||||||
c7:92:cf:ed:51:31:28:56:76:5c:da:8b:17:31:55:8c:a1:c2:
|
|
||||||
37:95:27:7b:b6:58:e5:92:ef:1e:fe:35:f1:44:ca:c7:1b:7b:
|
|
||||||
75:bf:e1:91:61:6d:8a:6f:35:8b:73:f4:d9:08:60:25:07:7a:
|
|
||||||
3e:c2:79:e7:ae:b4:70:cc:8a:30:cb:80:aa:47:1a:40:82:00:
|
|
||||||
a0:5e:01:67:d1:95:21:3c:b1:52:7d:f5:87:b6:43:41:df:b2:
|
|
||||||
a7:ee:3b:73:17:c4:19:2c:6b:7b:3c:26:9e:4c:00:e3:e8:07:
|
|
||||||
f2:e1:a1:31:79:57:be:b6:b1:a7:93:70:4e:e1:7d:bf:08:c5:
|
|
||||||
e7:a0:de:7d:82:20:24:f7:b0:3f:c2:94:36:88:ef:7b:7d:c0:
|
|
||||||
7f:8a:78:a1:8e:56:42:82:ce:82:e6:8e:3d:1b:b7:ca:dd:a9:
|
|
||||||
a8:e6:f9:a3:f4:4a:a4:a0:9c:15:6f:44:8c:48:20:e5:85:ed:
|
|
||||||
6f:85:22:41:1d:1f:fe:58:e5:43:ad:f2:c4:10:5a:10:ed:36:
|
|
||||||
10:98:ad:73:97:6a:e0:19:18:d6:32:26:03:3d:dd:84:5c:2e:
|
|
||||||
97:ca:a2:f5:63:f2:7a:16:f1:55:ca:d2:a1:54:09:8a:bb:23:
|
|
||||||
f0:53:36:51
|
|
||||||
-----BEGIN CERTIFICATE-----
|
|
||||||
MIIC+zCCAeOgAwIBAgICEAAwDQYJKoZIhvcNAQELBQAwPzEfMB0GA1UECgwWbmdp
|
|
||||||
bngtcHJveHkgdGVzdCBzdWl0ZTEcMBoGA1UEAwwTd3d3Lm5naW54LXByb3h5LnRs
|
|
||||||
ZDAgFw0yMzAyMDkwNDAyMjNaGA8yMDUwMDYyNzA0MDIyM1owHTEbMBkGA1UEAwwS
|
|
||||||
Ki5uZ2lueC1wcm94eS50ZXN0MIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIBCgKC
|
|
||||||
AQEA271U3gF+gk7A8V0S/Tr7IRlNRCVH6q3YEVzRZYivSfyOS8MBwQ1tIme9MWaf
|
|
||||||
SlAXnkezO7Mhcx+BVXNSR5v7hWvo2AnM4X0cFAMcroS0W+Xlx3H8H3QzT673jSEf
|
|
||||||
VY2Tx4RNkwGhHDeuhVxwLCHshzXDhtOzD5qwnYrNDknomcVMUL2obqcBPqfcz8NI
|
|
||||||
N47GiomwQQFY7kWU+pDr38gOt915dRMeB2nuVEeSGJ3gqe5OItH0ok2hR+2bNSpw
|
|
||||||
zGb7PvBJ9+5iKieh01J7/+kS2Vtr9hi/nJ1fACnSVLX4pKKbP/6m7RSuoP4TMxgz
|
|
||||||
F6mL/vx1ZQz7wtEegcpDib143QIDAQABoyEwHzAdBgNVHREEFjAUghIqLm5naW54
|
|
||||||
LXByb3h5LnRlc3QwDQYJKoZIhvcNAQELBQADggEBAEOnH0vs/x1wx/hu6/0VJSey
|
|
||||||
VMeSz+1RMShWdlzaixcxVYyhwjeVJ3u2WOWS7x7+NfFEyscbe3W/4ZFhbYpvNYtz
|
|
||||||
9NkIYCUHej7CeeeutHDMijDLgKpHGkCCAKBeAWfRlSE8sVJ99Ye2Q0HfsqfuO3MX
|
|
||||||
xBksa3s8Jp5MAOPoB/LhoTF5V762saeTcE7hfb8Ixeeg3n2CICT3sD/ClDaI73t9
|
|
||||||
wH+KeKGOVkKCzoLmjj0bt8rdqajm+aP0SqSgnBVvRIxIIOWF7W+FIkEdH/5Y5UOt
|
|
||||||
8sQQWhDtNhCYrXOXauAZGNYyJgM93YRcLpfKovVj8noW8VXK0qFUCYq7I/BTNlE=
|
|
||||||
-----END CERTIFICATE-----
|
|
||||||
@ -1,27 +0,0 @@
|
|||||||
-----BEGIN RSA PRIVATE KEY-----
|
|
||||||
MIIEowIBAAKCAQEA271U3gF+gk7A8V0S/Tr7IRlNRCVH6q3YEVzRZYivSfyOS8MB
|
|
||||||
wQ1tIme9MWafSlAXnkezO7Mhcx+BVXNSR5v7hWvo2AnM4X0cFAMcroS0W+Xlx3H8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6xIey0vObF2ve6XPSIr09
|
|
||||||
YtKObzF1jun4rnBwrXc5Zx0YXOK/0PemdtO6i6SqzCZYKI7nvGcIi80DfThi5cBU
|
|
||||||
uj4eBTGEQBrgM6jT9iK2izOKKkxDlqqA0nWec6kTm4Rvpa1Lg3Ibz4lRiR3Pq7Pp
|
|
||||||
v+8fp16SqUsUTkrWLADK2QKBgCRIhHf3X4yx2xBNz1JIDcwVpFBXPMxKWio0Ze7w
|
|
||||||
FPaIOq/sJkhZpyYc7EYkzhjHu2zvTLK2VZqJ32qrx/47NRYoNjz9qBpPyfcVfGzN
|
|
||||||
25LASPUVnFfWFpmnCXx9T0AVXMkpfjK857ZQcDvldcVfPmZKa3LTzlsqHjZR1uaC
|
|
||||||
sR7tAoGBANBfInPZVZRJfqqkPN1K8j4P7uCGjTIBmys/vxoilh1d0scTgZrdqt92
|
|
||||||
EKi/3UsJW2ndqQNDLbvi5kcW8a6UU3UB1LLvpyQ5zuS81x3+kKfv+5cDM8rt/M4A
|
|
||||||
MXnJA5eDZZ4SlHFzdblUv/MZdT+1x0tivMn3zFKNNj2SmaSGkQ0m
|
|
||||||
-----END RSA PRIVATE KEY-----
|
|
||||||
@ -1,71 +0,0 @@
|
|||||||
Certificate:
|
|
||||||
Data:
|
|
||||||
Version: 3 (0x2)
|
|
||||||
Serial Number: 4096 (0x1000)
|
|
||||||
Signature Algorithm: sha256WithRSAEncryption
|
|
||||||
Issuer: O=nginx-proxy test suite, CN=www.nginx-proxy.tld
|
|
||||||
Validity
|
|
||||||
Not Before: Feb 7 21:54:16 2023 GMT
|
|
||||||
Not After : Jun 25 21:54:16 2050 GMT
|
|
||||||
Subject: CN=http-only.nginx-proxy.test
|
|
||||||
Subject Public Key Info:
|
|
||||||
Public Key Algorithm: rsaEncryption
|
|
||||||
RSA Public-Key: (2048 bit)
|
|
||||||
Modulus:
|
|
||||||
00:b4:62:61:07:54:2e:6d:55:83:2d:24:b7:e2:15:
|
|
||||||
34:13:bd:79:21:e9:10:75:3f:4c:f8:ba:60:29:87:
|
|
||||||
e5:8e:2a:1e:fd:33:51:5a:8a:3a:6f:60:ff:24:f1:
|
|
||||||
1b:27:30:8c:ac:43:04:b7:79:cb:7a:ec:c6:08:a4:
|
|
||||||
a0:15:b0:0f:ee:6b:15:84:24:11:bc:85:2b:48:06:
|
|
||||||
04:0a:58:bb:8c:e8:4d:48:f5:06:c5:91:fe:5d:99:
|
|
||||||
0a:29:31:8a:f1:9b:0c:e0:39:75:a1:06:9b:d4:f5:
|
|
||||||
06:74:8f:46:5e:64:ba:2f:d0:3d:7c:3d:30:03:e9:
|
|
||||||
7c:35:17:69:04:f6:2e:29:d4:93:d6:d6:d2:6c:04:
|
|
||||||
38:06:21:06:05:30:8a:b9:9d:05:8d:12:6e:48:39:
|
|
||||||
bb:f6:93:4f:ba:a5:84:c7:96:2f:be:92:25:e9:d0:
|
|
||||||
95:2a:d9:23:8a:b3:28:0b:b6:19:1c:3b:be:a2:91:
|
|
||||||
70:44:a8:77:18:94:4b:df:61:f4:5c:c9:78:76:34:
|
|
||||||
b5:87:0f:c0:92:04:26:b6:ca:62:cd:9b:5d:eb:bf:
|
|
||||||
10:ac:df:af:72:5f:af:09:38:b1:dc:e1:3d:13:db:
|
|
||||||
a0:ac:b7:2e:ca:39:5c:4c:f1:1e:81:a8:b4:44:a2:
|
|
||||||
72:d5:3b:c0:71:cc:dc:16:0d:fa:38:96:44:b3:00:
|
|
||||||
d6:65
|
|
||||||
Exponent: 65537 (0x10001)
|
|
||||||
X509v3 extensions:
|
|
||||||
X509v3 Subject Alternative Name:
|
|
||||||
DNS:http-only.nginx-proxy.test
|
|
||||||
Signature Algorithm: sha256WithRSAEncryption
|
|
||||||
3b:54:95:48:4d:f6:93:38:42:40:02:ab:b7:17:3b:50:3b:ca:
|
|
||||||
c7:12:69:b0:da:cb:d7:3e:0e:1f:bf:a2:59:c7:fe:c2:5c:43:
|
|
||||||
84:92:b9:3a:be:8f:7e:2e:81:3c:ed:f3:a9:77:21:c2:35:f1:
|
|
||||||
da:cf:3a:1e:e2:ee:a2:ce:72:55:97:87:0e:ad:59:61:f7:75:
|
|
||||||
46:c0:2b:d4:88:b7:36:97:11:fb:5e:28:89:e9:2a:92:f1:15:
|
|
||||||
f1:43:8e:c1:38:85:8d:3a:26:7d:25:72:93:17:96:8d:5a:ed:
|
|
||||||
e8:73:3a:d5:8d:80:f2:af:38:84:ff:85:2e:d1:36:7d:2e:e1:
|
|
||||||
f0:2c:d8:15:5f:fc:c5:70:5d:25:6a:22:f3:2a:cd:0f:25:ad:
|
|
||||||
d4:93:d3:9a:3e:50:bc:da:a5:6c:86:ea:1d:d9:b9:c5:90:db:
|
|
||||||
f5:02:c8:c9:77:5c:ef:77:fe:74:60:41:33:d9:3c:a2:e1:73:
|
|
||||||
aa:14:18:5d:36:58:c8:41:63:4c:59:0e:4b:3d:c5:65:5a:01:
|
|
||||||
b0:16:50:0f:d0:4f:0d:ca:97:f6:11:47:06:6b:b1:ae:bb:26:
|
|
||||||
30:34:8b:7a:91:5d:8a:22:c7:f9:05:0d:bb:a5:b7:60:c0:20:
|
|
||||||
ce:d0:0e:c0:66:b3:e7:c4:61:ec:c5:40:e6:52:11:41:c3:11:
|
|
||||||
18:04:c7:1e
|
|
||||||
-----BEGIN CERTIFICATE-----
|
|
||||||
MIIDCzCCAfOgAwIBAgICEAAwDQYJKoZIhvcNAQELBQAwPzEfMB0GA1UECgwWbmdp
|
|
||||||
bngtcHJveHkgdGVzdCBzdWl0ZTEcMBoGA1UEAwwTd3d3Lm5naW54LXByb3h5LnRs
|
|
||||||
ZDAgFw0yMzAyMDcyMTU0MTZaGA8yMDUwMDYyNTIxNTQxNlowJTEjMCEGA1UEAwwa
|
|
||||||
aHR0cC1vbmx5Lm5naW54LXByb3h5LnRlc3QwggEiMA0GCSqGSIb3DQEBAQUAA4IB
|
|
||||||
DwAwggEKAoIBAQC0YmEHVC5tVYMtJLfiFTQTvXkh6RB1P0z4umAph+WOKh79M1Fa
|
|
||||||
ijpvYP8k8RsnMIysQwS3ect67MYIpKAVsA/uaxWEJBG8hStIBgQKWLuM6E1I9QbF
|
|
||||||
kf5dmQopMYrxmwzgOXWhBpvU9QZ0j0ZeZLov0D18PTAD6Xw1F2kE9i4p1JPW1tJs
|
|
||||||
BDgGIQYFMIq5nQWNEm5IObv2k0+6pYTHli++kiXp0JUq2SOKsygLthkcO76ikXBE
|
|
||||||
qHcYlEvfYfRcyXh2NLWHD8CSBCa2ymLNm13rvxCs369yX68JOLHc4T0T26Csty7K
|
|
||||||
OVxM8R6BqLREonLVO8BxzNwWDfo4lkSzANZlAgMBAAGjKTAnMCUGA1UdEQQeMByC
|
|
||||||
Gmh0dHAtb25seS5uZ2lueC1wcm94eS50ZXN0MA0GCSqGSIb3DQEBCwUAA4IBAQA7
|
|
||||||
VJVITfaTOEJAAqu3FztQO8rHEmmw2svXPg4fv6JZx/7CXEOEkrk6vo9+LoE87fOp
|
|
||||||
dyHCNfHazzoe4u6iznJVl4cOrVlh93VGwCvUiLc2lxH7XiiJ6SqS8RXxQ47BOIWN
|
|
||||||
OiZ9JXKTF5aNWu3oczrVjYDyrziE/4Uu0TZ9LuHwLNgVX/zFcF0laiLzKs0PJa3U
|
|
||||||
k9OaPlC82qVshuod2bnFkNv1AsjJd1zvd/50YEEz2Tyi4XOqFBhdNljIQWNMWQ5L
|
|
||||||
PcVlWgGwFlAP0E8Nypf2EUcGa7GuuyYwNIt6kV2KIsf5BQ27pbdgwCDO0A7AZrPn
|
|
||||||
xGHsxUDmUhFBwxEYBMce
|
|
||||||
-----END CERTIFICATE-----
|
|
||||||
@ -1,27 +0,0 @@
|
|||||||
-----BEGIN RSA PRIVATE KEY-----
|
|
||||||
MIIEpAIBAAKCAQEAtGJhB1QubVWDLSS34hU0E715IekQdT9M+LpgKYfljioe/TNR
|
|
||||||
Woo6b2D/JPEbJzCMrEMEt3nLeuzGCKSgFbAP7msVhCQRvIUrSAYECli7jOhNSPUG
|
|
||||||
xZH+XZkKKT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U8
|
|
||||||
oSiljbSwEyMh6Oe/nOkYkIKtr4AzrCoGt11piG7ohGW0lS9suMijnMqiquI+JP5+
|
|
||||||
KyinLoUy761aR17nf+9e62mpkZw6hUqQTGi7Irs0SHUXhMpaCfDi/Ua9MiW+yVuB
|
|
||||||
ds6+xBgeciZwWxMlXOwy2p0CgYEAm+YWiSK3Mq0fo7uEvBn9Fps2z+ciLoZNdppL
|
|
||||||
n6gkMX2MaeQ3PVi/wxoRYX+tsL+c973yf2vwEnw0R7Dlutt6dc9VgxNWj4GE0GMe
|
|
||||||
Tiao7Uom7Tf4p7wC9+r9rI/zOz2f8OxRIK18wtbShWfR5fx1dCWUXmGb3+jUse1O
|
|
||||||
4Qk2FcECgYAvSvGFoJb8tuHFEYYHBbjficmvTUsrTE+EhxPqWKFhKfF19fFFIupy
|
|
||||||
XBCrN6nwrh+/YMxZXeIRbbTTf814cOO7PjLeNhnfhJZkaJq1HzbYe3bOurna3qrm
|
|
||||||
Ra3xiM8Ld2PyGnZPXf8+AWhMhuPkLX1KFVTCAxwCpmTZCHtiGCmXMA==
|
|
||||||
-----END RSA PRIVATE KEY-----
|
|
||||||
@ -1,71 +0,0 @@
|
|||||||
Certificate:
|
|
||||||
Data:
|
|
||||||
Version: 3 (0x2)
|
|
||||||
Serial Number: 4096 (0x1000)
|
|
||||||
Signature Algorithm: sha256WithRSAEncryption
|
|
||||||
Issuer: O=nginx-proxy test suite, CN=www.nginx-proxy.tld
|
|
||||||
Validity
|
|
||||||
Not Before: Feb 7 21:53:19 2023 GMT
|
|
||||||
Not After : Jun 25 21:53:19 2050 GMT
|
|
||||||
Subject: CN=https-and-http.nginx-proxy.test
|
|
||||||
Subject Public Key Info:
|
|
||||||
Public Key Algorithm: rsaEncryption
|
|
||||||
RSA Public-Key: (2048 bit)
|
|
||||||
Modulus:
|
|
||||||
00:b7:97:85:d1:7f:6b:50:29:f3:87:b7:4e:f5:25:
|
|
||||||
40:6a:d8:fa:a1:63:3c:4a:2e:68:4a:c6:8b:38:df:
|
|
||||||
07:81:d0:08:9d:fc:17:f5:37:28:7f:31:e6:f3:81:
|
|
||||||
28:4e:22:b6:bd:a2:4e:f2:2f:e5:0f:dd:55:3c:e1:
|
|
||||||
04:84:4c:45:1b:1a:ae:b7:f0:2a:da:43:05:71:91:
|
|
||||||
92:b8:d1:49:fe:80:0a:53:b9:66:da:54:60:9a:fc:
|
|
||||||
e1:b2:e8:28:48:7f:96:94:3c:92:a3:b2:37:f6:7a:
|
|
||||||
c2:de:0b:12:f0:ae:4e:92:fe:2d:c1:b2:95:28:1f:
|
|
||||||
88:8d:79:99:81:19:ae:22:a4:95:f5:9f:db:25:8e:
|
|
||||||
1d:cf:43:cd:6f:85:93:5f:79:ee:f8:f3:d4:82:e1:
|
|
||||||
e9:4d:c9:ad:ae:5b:92:43:3a:3c:71:51:70:f7:3e:
|
|
||||||
bd:1b:24:52:6a:a3:cf:54:72:57:ed:fe:72:ea:96:
|
|
||||||
9b:5a:02:02:a7:df:85:b7:68:ae:1e:07:77:9f:59:
|
|
||||||
a5:a0:8b:28:c2:c8:b7:bb:8a:42:50:df:05:73:bf:
|
|
||||||
9c:55:13:b5:82:79:77:40:57:a4:8f:88:a5:71:50:
|
|
||||||
d7:70:b0:4d:0c:d9:86:b3:9b:db:8a:20:bd:19:68:
|
|
||||||
10:52:2d:53:ba:0e:2e:1c:ad:80:54:bb:b6:c9:ab:
|
|
||||||
11:39
|
|
||||||
Exponent: 65537 (0x10001)
|
|
||||||
X509v3 extensions:
|
|
||||||
X509v3 Subject Alternative Name:
|
|
||||||
DNS:https-and-http.nginx-proxy.test
|
|
||||||
Signature Algorithm: sha256WithRSAEncryption
|
|
||||||
2c:f3:e5:47:3f:8e:5a:28:b1:df:e5:95:50:85:6f:27:2f:a6:
|
|
||||||
8d:f1:5e:cf:df:e2:52:66:97:61:36:59:81:26:25:19:99:c9:
|
|
||||||
93:e5:85:cb:ca:69:af:4b:21:a3:d2:7a:bf:b5:5e:2d:42:fb:
|
|
||||||
99:f8:22:58:e5:bf:79:b8:8a:74:7e:c6:94:14:d9:f2:27:63:
|
|
||||||
b6:e5:74:21:5b:59:fb:f6:c8:a9:28:fb:60:f7:5e:bd:c2:e6:
|
|
||||||
74:24:14:96:61:95:6c:c2:66:b4:52:25:a1:85:5a:97:e5:68:
|
|
||||||
5c:62:cf:69:3b:b0:a9:56:d8:e3:5f:74:dc:84:18:d5:3e:4f:
|
|
||||||
c9:35:39:26:88:dc:9b:80:d9:40:e1:4f:09:27:8d:d2:89:55:
|
|
||||||
30:91:02:86:35:04:95:1e:1d:58:14:5b:c6:e0:2e:a7:bf:a8:
|
|
||||||
f6:2b:76:8a:4e:71:79:bc:c0:04:cd:db:81:73:46:ce:68:ed:
|
|
||||||
25:b0:0e:42:8d:96:64:77:3b:f4:9d:1a:c9:f6:78:4c:56:4f:
|
|
||||||
92:17:29:3d:80:50:71:77:4b:a8:29:c2:12:fc:ad:0a:37:81:
|
|
||||||
38:4c:fb:54:99:4d:12:5f:98:dc:d1:a9:7b:08:45:c4:6f:7e:
|
|
||||||
fe:00:e0:db:79:fe:d1:28:e3:8e:82:d1:fb:bc:0a:c4:42:93:
|
|
||||||
c9:5e:eb:ba
|
|
||||||
-----BEGIN CERTIFICATE-----
|
|
||||||
MIIDFTCCAf2gAwIBAgICEAAwDQYJKoZIhvcNAQELBQAwPzEfMB0GA1UECgwWbmdp
|
|
||||||
bngtcHJveHkgdGVzdCBzdWl0ZTEcMBoGA1UEAwwTd3d3Lm5naW54LXByb3h5LnRs
|
|
||||||
ZDAgFw0yMzAyMDcyMTUzMTlaGA8yMDUwMDYyNTIxNTMxOVowKjEoMCYGA1UEAwwf
|
|
||||||
aHR0cHMtYW5kLWh0dHAubmdpbngtcHJveHkudGVzdDCCASIwDQYJKoZIhvcNAQEB
|
|
||||||
BQADggEPADCCAQoCggEBALeXhdF/a1Ap84e3TvUlQGrY+qFjPEouaErGizjfB4HQ
|
|
||||||
CJ38F/U3KH8x5vOBKE4itr2iTvIv5Q/dVTzhBIRMRRsarrfwKtpDBXGRkrjRSf6A
|
|
||||||
ClO5ZtpUYJr84bLoKEh/lpQ8kqOyN/Z6wt4LEvCuTpL+LcGylSgfiI15mYEZriKk
|
|
||||||
lfWf2yWOHc9DzW+Fk1957vjz1ILh6U3Jra5bkkM6PHFRcPc+vRskUmqjz1RyV+3+
|
|
||||||
cuqWm1oCAqffhbdorh4Hd59ZpaCLKMLIt7uKQlDfBXO/nFUTtYJ5d0BXpI+IpXFQ
|
|
||||||
13CwTQzZhrOb24ogvRloEFItU7oOLhytgFS7tsmrETkCAwEAAaMuMCwwKgYDVR0R
|
|
||||||
BCMwIYIfaHR0cHMtYW5kLWh0dHAubmdpbngtcHJveHkudGVzdDANBgkqhkiG9w0B
|
|
||||||
AQsFAAOCAQEALPPlRz+OWiix3+WVUIVvJy+mjfFez9/iUmaXYTZZgSYlGZnJk+WF
|
|
||||||
y8ppr0sho9J6v7VeLUL7mfgiWOW/ebiKdH7GlBTZ8idjtuV0IVtZ+/bIqSj7YPde
|
|
||||||
vcLmdCQUlmGVbMJmtFIloYVal+VoXGLPaTuwqVbY41903IQY1T5PyTU5Jojcm4DZ
|
|
||||||
QOFPCSeN0olVMJEChjUElR4dWBRbxuAup7+o9it2ik5xebzABM3bgXNGzmjtJbAO
|
|
||||||
Qo2WZHc79J0ayfZ4TFZPkhcpPYBQcXdLqCnCEvytCjeBOEz7VJlNEl+Y3NGpewhF
|
|
||||||
xG9+/gDg23n+0SjjjoLR+7wKxEKTyV7rug==
|
|
||||||
-----END CERTIFICATE-----
|
|
||||||
@ -1,27 +0,0 @@
|
|||||||
-----BEGIN RSA PRIVATE KEY-----
|
|
||||||
MIIEpAIBAAKCAQEAt5eF0X9rUCnzh7dO9SVAatj6oWM8Si5oSsaLON8HgdAInfwX
|
|
||||||
9TcofzHm84EoTiK2vaJO8i/lD91VPOEEhExFGxqut/Aq2kMFcZGSuNFJ/oAKU7lm
|
|
||||||
2lRgmvzhsugoSH+WlD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acu9dOUzgw
|
|
||||||
2ewpPcIvawDY+cxwAsHO3MDneVWPX4JBoGa7pwvwRTL1hwBqYMRJwwbD5CKObcQI
|
|
||||||
V/KxV28Eqo2N77tt1z2x9/E99u/4yTI1P0gm9ejfeVlL1RpyIMPPBcEujZ0Z6WXC
|
|
||||||
X3I63k0KLtajHRa2erIf4tkCgYAfunAgwTuX5JqXO3xfcEl033WY6deGUUvgU2Dw
|
|
||||||
Sdu1viY8gVNyQmwmMGwAZsquWxsJtRoibgM7IucsTml+b8v2j7hstP3IqCjn+9Wr
|
|
||||||
swDG28WTyXNvu31JgP04dLaRoVIAlOdsofym6OiLNvozO0M3VsziXMjZnVlK8zfP
|
|
||||||
dORkQQKBgQDXAJEJPygxVA+bF104dzCMWGmU7K8ShEWC5eOdKK4KWf9bNDpY6M6c
|
|
||||||
i6zga/xBbj7e3Bxqprpp8Wy2gIsnYiVo4V9EQethbLdomPxOpBMNMARw81rL1CpO
|
|
||||||
jbHB7bIDcKs2tQoZEXUW86ZxC8sdaDaWTJTfUO0RpJow6ZO3yvxVIQ==
|
|
||||||
-----END RSA PRIVATE KEY-----
|
|
||||||
@ -1,71 +0,0 @@
|
|||||||
Certificate:
|
|
||||||
Data:
|
|
||||||
Version: 3 (0x2)
|
|
||||||
Serial Number: 4096 (0x1000)
|
|
||||||
Signature Algorithm: sha256WithRSAEncryption
|
|
||||||
Issuer: O=nginx-proxy test suite, CN=www.nginx-proxy.tld
|
|
||||||
Validity
|
|
||||||
Not Before: Feb 7 21:53:49 2023 GMT
|
|
||||||
Not After : Jun 25 21:53:49 2050 GMT
|
|
||||||
Subject: CN=https-only.nginx-proxy.test
|
|
||||||
Subject Public Key Info:
|
|
||||||
Public Key Algorithm: rsaEncryption
|
|
||||||
RSA Public-Key: (2048 bit)
|
|
||||||
Modulus:
|
|
||||||
00:d9:87:48:02:85:f4:5f:0d:90:7e:4c:4f:13:89:
|
|
||||||
41:ca:41:15:c2:6f:fd:a8:c7:17:83:c6:dd:8c:fe:
|
|
||||||
19:a4:b2:6b:0b:35:4f:b4:3d:7c:40:0a:04:33:2a:
|
|
||||||
fd:10:72:f7:63:63:99:5b:3d:ec:78:ee:c6:4d:c8:
|
|
||||||
0e:4c:be:f2:3f:e3:02:74:57:9a:c1:fe:15:95:63:
|
|
||||||
4e:e7:2c:eb:70:f2:6b:c8:ba:01:a2:ca:a1:c7:76:
|
|
||||||
ff:38:e4:c2:b0:66:fc:85:d2:af:0f:22:81:d4:82:
|
|
||||||
eb:d5:b0:e6:69:14:37:dd:8d:ad:29:ce:93:68:5a:
|
|
||||||
ce:f4:77:76:6f:78:13:b6:c8:2f:fe:e0:b6:7e:fb:
|
|
||||||
29:16:be:e2:f5:45:3b:39:5b:52:dc:26:b7:ca:0c:
|
|
||||||
b6:1c:fc:a8:38:0b:dd:c1:f4:04:9b:2d:38:c9:a5:
|
|
||||||
2d:3e:f1:42:88:53:a2:3b:17:cf:d5:3c:2b:d6:6a:
|
|
||||||
7f:6f:05:8d:c5:b7:5d:64:1e:83:1b:e7:ec:80:3d:
|
|
||||||
6d:34:c1:66:b2:e6:5d:d9:a7:6e:46:75:14:bf:10:
|
|
||||||
16:c5:fc:47:8e:63:fa:e5:b4:bd:f2:b9:e0:cb:ea:
|
|
||||||
75:f9:68:ee:7d:8f:ea:8f:1a:9f:34:27:7a:4a:9f:
|
|
||||||
85:fd:3e:17:a7:96:c3:d0:4e:50:a2:a2:e0:45:92:
|
|
||||||
d0:b5
|
|
||||||
Exponent: 65537 (0x10001)
|
|
||||||
X509v3 extensions:
|
|
||||||
X509v3 Subject Alternative Name:
|
|
||||||
DNS:https-only.nginx-proxy.test
|
|
||||||
Signature Algorithm: sha256WithRSAEncryption
|
|
||||||
8a:52:46:42:a9:74:18:6a:52:90:ef:a4:e9:c5:54:d5:97:3a:
|
|
||||||
ff:8b:c2:76:4f:9e:47:aa:e1:ea:e5:b9:af:9d:33:e3:85:17:
|
|
||||||
54:7d:32:bd:ac:90:3f:5c:d2:a1:42:17:52:2b:b1:83:e5:c3:
|
|
||||||
bf:81:f0:e7:38:e2:88:67:7b:d8:59:fe:f9:94:99:ba:be:f4:
|
|
||||||
3c:24:b2:c7:9e:f0:98:21:c6:2d:c2:e8:f3:67:bd:62:00:aa:
|
|
||||||
ce:34:fa:b4:53:6d:c1:09:5e:55:bd:43:aa:86:c6:f8:c5:83:
|
|
||||||
46:3a:49:12:a2:ec:30:36:0c:99:44:74:09:9d:cc:4b:98:1f:
|
|
||||||
7e:c9:9b:68:a0:f8:1e:00:14:d0:da:2a:bf:c8:ca:a8:1c:10:
|
|
||||||
b5:68:a2:f1:41:93:0c:f3:3f:c0:c6:53:3c:8d:a7:dd:a5:7b:
|
|
||||||
35:cc:44:e0:5b:6d:c5:cb:33:6f:c1:43:7e:06:df:21:99:11:
|
|
||||||
b3:91:41:b4:5e:f0:37:1e:8e:e5:73:85:dc:4a:21:d5:41:f9:
|
|
||||||
4e:b8:f5:ed:21:93:09:91:c2:8c:6b:04:a4:84:ab:3a:fe:35:
|
|
||||||
64:fa:6b:a7:8d:40:a6:64:89:30:84:ac:28:99:5a:01:79:77:
|
|
||||||
c0:df:88:da:a9:75:5f:c4:51:ae:a8:45:7b:d2:e1:a2:81:29:
|
|
||||||
60:cd:7b:cd
|
|
||||||
-----BEGIN CERTIFICATE-----
|
|
||||||
MIIDDTCCAfWgAwIBAgICEAAwDQYJKoZIhvcNAQELBQAwPzEfMB0GA1UECgwWbmdp
|
|
||||||
bngtcHJveHkgdGVzdCBzdWl0ZTEcMBoGA1UEAwwTd3d3Lm5naW54LXByb3h5LnRs
|
|
||||||
ZDAgFw0yMzAyMDcyMTUzNDlaGA8yMDUwMDYyNTIxNTM0OVowJjEkMCIGA1UEAwwb
|
|
||||||
aHR0cHMtb25seS5uZ2lueC1wcm94eS50ZXN0MIIBIjANBgkqhkiG9w0BAQEFAAOC
|
|
||||||
AQ8AMIIBCgKCAQEA2YdIAoX0Xw2QfkxPE4lBykEVwm/9qMcXg8bdjP4Zp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n5eP6CsYmDWLpHQNyXY5qcEcCgYAzDBWt5O3JF/Or2Yr8zEAb
|
|
||||||
qbIq544yx69jfQDakMnQe72Yf48Quuz9N+b6zpnjJWEJLMU+TL+cJUgN/SzAqyDh
|
|
||||||
96zTaf/ENOCbiuAWUtIelUfNcf7iFm6rnodUsl0pZ8uL5w+iA+i4zjrNy+WtdG2k
|
|
||||||
OrNAwd345L1dHAaJeSSaJQKBgQCUnF3r7Fa/TCpt87LHwSQK+sqWyRf+/9IbiRDI
|
|
||||||
pVL/s8FmVPHw7jIHhHwuo7lCImnz4LGy5C6oOnIizIRAy/04Ty0Hd8ri5YmPlbHI
|
|
||||||
8A8gbMiB7zeNU1zlXP5jzFPyo2tMhLyGH5gnTdwOtfnPD/dCPe45ZJYyISIOg3O0
|
|
||||||
3peMBwKBgH20cskAOCNclfoG+Nis52h8FqmDlflJ8waUarvk26JhO1e009kOytw8
|
|
||||||
x/qSuttpGtTG+4fdc2wJvFNczr4h9ZlftBdgZXj8PKgRpcIe8q97Xg8PUj+Xfu/t
|
|
||||||
vD/QV+tVcGoAMsQq4NeFxiTbPfwVyXdYFT1XVCu6JEdLL+gpWh5W
|
|
||||||
-----END RSA PRIVATE KEY-----
|
|
||||||
@ -1,36 +0,0 @@
|
|||||||
services:
|
|
||||||
sut:
|
|
||||||
image: nginxproxy/nginx-proxy:test
|
|
||||||
volumes:
|
|
||||||
- /var/run/docker.sock:/tmp/docker.sock:ro
|
|
||||||
- ./withdefault.certs:/etc/nginx/certs:ro
|
|
||||||
https-and-http:
|
|
||||||
image: web
|
|
||||||
expose:
|
|
||||||
- "81"
|
|
||||||
environment:
|
|
||||||
WEB_PORTS: "81"
|
|
||||||
VIRTUAL_HOST: https-and-http.nginx-proxy.test
|
|
||||||
https-only:
|
|
||||||
image: web
|
|
||||||
expose:
|
|
||||||
- "82"
|
|
||||||
environment:
|
|
||||||
WEB_PORTS: "82"
|
|
||||||
VIRTUAL_HOST: https-only.nginx-proxy.test
|
|
||||||
HTTPS_METHOD: nohttp
|
|
||||||
http-only:
|
|
||||||
image: web
|
|
||||||
expose:
|
|
||||||
- "83"
|
|
||||||
environment:
|
|
||||||
WEB_PORTS: "83"
|
|
||||||
VIRTUAL_HOST: http-only.nginx-proxy.test
|
|
||||||
HTTPS_METHOD: nohttps
|
|
||||||
missing-cert:
|
|
||||||
image: web
|
|
||||||
expose:
|
|
||||||
- "84"
|
|
||||||
environment:
|
|
||||||
WEB_PORTS: "84"
|
|
||||||
VIRTUAL_HOST: missing-cert.nginx-proxy.test
|
|
||||||
@ -1,99 +0,0 @@
|
|||||||
import os.path
|
|
||||||
import re
|
|
||||||
|
|
||||||
import backoff
|
|
||||||
import pytest
|
|
||||||
import requests
|
|
||||||
|
|
||||||
|
|
||||||
@pytest.fixture
|
|
||||||
def data_dir():
|
|
||||||
return f"{os.path.splitext(__file__)[0]}.data"
|
|
||||||
|
|
||||||
|
|
||||||
@pytest.fixture
|
|
||||||
def docker_compose_file(data_dir, compose_file):
|
|
||||||
return os.path.join(data_dir, compose_file)
|
|
||||||
|
|
||||||
|
|
||||||
@pytest.fixture
|
|
||||||
def get(docker_compose, nginxproxy, want_err_re):
|
|
||||||
|
|
||||||
@backoff.on_exception(
|
|
||||||
backoff.constant,
|
|
||||||
requests.exceptions.RequestException,
|
|
||||||
giveup=lambda e: want_err_re and want_err_re.search(str(e)),
|
|
||||||
interval=.3,
|
|
||||||
max_tries=30,
|
|
||||||
jitter=None)
|
|
||||||
def _get(url):
|
|
||||||
return nginxproxy.get(url, allow_redirects=False)
|
|
||||||
|
|
||||||
return _get
|
|
||||||
|
|
||||||
|
|
||||||
INTERNAL_ERR_RE = re.compile("TLSV1_ALERT_INTERNAL_ERROR")
|
|
||||||
CONNECTION_REFUSED_RE = re.compile("Connection refused")
|
|
||||||
|
|
||||||
|
|
||||||
@pytest.mark.parametrize("compose_file,url,want_code,want_err_re", [
|
|
||||||
# Has default.crt.
|
|
||||||
("withdefault.yml", "http://https-and-http.nginx-proxy.test/", 301, None),
|
|
||||||
("withdefault.yml", "https://https-and-http.nginx-proxy.test/", 200, None),
|
|
||||||
("withdefault.yml", "http://https-only.nginx-proxy.test/", 503, None),
|
|
||||||
("withdefault.yml", "https://https-only.nginx-proxy.test/", 200, None),
|
|
||||||
("withdefault.yml", "http://http-only.nginx-proxy.test/", 200, None),
|
|
||||||
("withdefault.yml", "https://http-only.nginx-proxy.test/", 503, None),
|
|
||||||
("withdefault.yml", "http://missing-cert.nginx-proxy.test/", 200, None),
|
|
||||||
("withdefault.yml", "https://missing-cert.nginx-proxy.test/", 500, None),
|
|
||||||
("withdefault.yml", "http://unknown.nginx-proxy.test/", 503, None),
|
|
||||||
("withdefault.yml", "https://unknown.nginx-proxy.test/", 503, None),
|
|
||||||
# Same as withdefault.yml, except there is no default.crt.
|
|
||||||
("nodefault.yml", "http://https-and-http.nginx-proxy.test/", 301, None),
|
|
||||||
("nodefault.yml", "https://https-and-http.nginx-proxy.test/", 200, None),
|
|
||||||
("nodefault.yml", "http://https-only.nginx-proxy.test/", 503, None),
|
|
||||||
("nodefault.yml", "https://https-only.nginx-proxy.test/", 200, None),
|
|
||||||
("nodefault.yml", "http://http-only.nginx-proxy.test/", 200, None),
|
|
||||||
("nodefault.yml", "https://http-only.nginx-proxy.test/", None, INTERNAL_ERR_RE),
|
|
||||||
("nodefault.yml", "http://missing-cert.nginx-proxy.test/", 200, None),
|
|
||||||
("nodefault.yml", "https://missing-cert.nginx-proxy.test/", None, INTERNAL_ERR_RE),
|
|
||||||
("nodefault.yml", "http://unknown.nginx-proxy.test/", 503, None),
|
|
||||||
("nodefault.yml", "https://unknown.nginx-proxy.test/", None, INTERNAL_ERR_RE),
|
|
||||||
# HTTPS_METHOD=nohttp on nginx-proxy, HTTPS_METHOD unset on the app container.
|
|
||||||
("nohttp.yml", "http://https-only.nginx-proxy.test/", None, CONNECTION_REFUSED_RE),
|
|
||||||
("nohttp.yml", "https://https-only.nginx-proxy.test/", 200, None),
|
|
||||||
("nohttp.yml", "http://unknown.nginx-proxy.test/", None, CONNECTION_REFUSED_RE),
|
|
||||||
("nohttp.yml", "https://unknown.nginx-proxy.test/", 503, None),
|
|
||||||
# HTTPS_METHOD=redirect on nginx-proxy, HTTPS_METHOD=nohttp on the app container.
|
|
||||||
("nohttp-on-app.yml", "http://https-only.nginx-proxy.test/", None, CONNECTION_REFUSED_RE),
|
|
||||||
("nohttp-on-app.yml", "https://https-only.nginx-proxy.test/", 200, None),
|
|
||||||
("nohttp-on-app.yml", "http://unknown.nginx-proxy.test/", None, CONNECTION_REFUSED_RE),
|
|
||||||
("nohttp-on-app.yml", "https://unknown.nginx-proxy.test/", 503, None),
|
|
||||||
# Same as nohttp.yml, except there is a vhost with a missing cert. This causes its
|
|
||||||
# HTTPS_METHOD=nohttp setting to effectively become HTTPS_METHOD=noredirect. This means that
|
|
||||||
# there will be a plain http server solely to support that vhost, so http requests to other
|
|
||||||
# vhosts get a 503, not a connection refused error.
|
|
||||||
("nohttp-with-missing-cert.yml", "http://https-only.nginx-proxy.test/", 503, None),
|
|
||||||
("nohttp-with-missing-cert.yml", "https://https-only.nginx-proxy.test/", 200, None),
|
|
||||||
("nohttp-with-missing-cert.yml", "http://missing-cert.nginx-proxy.test/", 200, None),
|
|
||||||
("nohttp-with-missing-cert.yml", "https://missing-cert.nginx-proxy.test/", 500, None),
|
|
||||||
("nohttp-with-missing-cert.yml", "http://unknown.nginx-proxy.test/", 503, None),
|
|
||||||
("nohttp-with-missing-cert.yml", "https://unknown.nginx-proxy.test/", 503, None),
|
|
||||||
# HTTPS_METHOD=nohttps on nginx-proxy, HTTPS_METHOD unset on the app container.
|
|
||||||
("nohttps.yml", "http://http-only.nginx-proxy.test/", 200, None),
|
|
||||||
("nohttps.yml", "https://http-only.nginx-proxy.test/", None, CONNECTION_REFUSED_RE),
|
|
||||||
("nohttps.yml", "http://unknown.nginx-proxy.test/", 503, None),
|
|
||||||
("nohttps.yml", "https://unknown.nginx-proxy.test/", None, CONNECTION_REFUSED_RE),
|
|
||||||
# HTTPS_METHOD=redirect on nginx-proxy, HTTPS_METHOD=nohttps on the app container.
|
|
||||||
("nohttps-on-app.yml", "http://http-only.nginx-proxy.test/", 200, None),
|
|
||||||
("nohttps-on-app.yml", "https://http-only.nginx-proxy.test/", None, CONNECTION_REFUSED_RE),
|
|
||||||
("nohttps-on-app.yml", "http://unknown.nginx-proxy.test/", 503, None),
|
|
||||||
("nohttps-on-app.yml", "https://unknown.nginx-proxy.test/", None, CONNECTION_REFUSED_RE),
|
|
||||||
])
|
|
||||||
def test_fallback(get, url, want_code, want_err_re):
|
|
||||||
if want_err_re is None:
|
|
||||||
r = get(url)
|
|
||||||
assert r.status_code == want_code
|
|
||||||
else:
|
|
||||||
with pytest.raises(requests.exceptions.RequestException, match=want_err_re):
|
|
||||||
get(url)
|
|
||||||
@ -1,31 +0,0 @@
|
|||||||
import re
|
|
||||||
|
|
||||||
|
|
||||||
def test_keepalive_disabled(docker_compose, nginxproxy):
|
|
||||||
r = nginxproxy.get("http://keepalive-disabled.nginx-proxy.test/headers")
|
|
||||||
assert r.status_code == 200
|
|
||||||
assert re.search(fr'(?m)^(?i:Connection): close$', r.text)
|
|
||||||
|
|
||||||
def test_keepalive_disabled_other_headers_ok(docker_compose, nginxproxy):
|
|
||||||
"""Make sure the other proxy_set_header headers are still set.
|
|
||||||
|
|
||||||
According to the nginx docs [1], any proxy_set_header directive in a block
|
|
||||||
disables inheritance of proxy_set_header directives in a parent block. Make
|
|
||||||
sure that doesn't happen.
|
|
||||||
|
|
||||||
[1] https://nginx.org/en/docs/http/ngx_http_proxy_module.html#proxy_set_header
|
|
||||||
"""
|
|
||||||
r = nginxproxy.get("http://keepalive-disabled.nginx-proxy.test/headers")
|
|
||||||
assert r.status_code == 200
|
|
||||||
assert re.search(fr'(?m)^(?i:X-Real-IP): ', r.text)
|
|
||||||
|
|
||||||
def test_keepalive_enabled(docker_compose, nginxproxy):
|
|
||||||
r = nginxproxy.get("http://keepalive-enabled.nginx-proxy.test/headers")
|
|
||||||
assert r.status_code == 200
|
|
||||||
assert not re.search(fr'(?m)^(?i:Connection):', r.text)
|
|
||||||
|
|
||||||
def test_keepalive_enabled_other_headers_ok(docker_compose, nginxproxy):
|
|
||||||
"""See the docstring for the disabled case above."""
|
|
||||||
r = nginxproxy.get("http://keepalive-enabled.nginx-proxy.test/headers")
|
|
||||||
assert r.status_code == 200
|
|
||||||
assert re.search(fr'(?m)^(?i:X-Real-IP): ', r.text)
|
|
||||||
@ -1,25 +0,0 @@
|
|||||||
keepalive-disabled:
|
|
||||||
image: web
|
|
||||||
expose:
|
|
||||||
- "80"
|
|
||||||
environment:
|
|
||||||
WEB_PORTS: 80
|
|
||||||
VIRTUAL_HOST: keepalive-disabled.nginx-proxy.test
|
|
||||||
|
|
||||||
keepalive-enabled:
|
|
||||||
image: web
|
|
||||||
expose:
|
|
||||||
- "80"
|
|
||||||
environment:
|
|
||||||
WEB_PORTS: 80
|
|
||||||
VIRTUAL_HOST: keepalive-enabled.nginx-proxy.test
|
|
||||||
labels:
|
|
||||||
com.github.nginx-proxy.nginx-proxy.keepalive: "64"
|
|
||||||
|
|
||||||
|
|
||||||
sut:
|
|
||||||
image: nginxproxy/nginx-proxy:test
|
|
||||||
volumes:
|
|
||||||
- /var/run/docker.sock:/tmp/docker.sock:ro
|
|
||||||
environment:
|
|
||||||
HTTPS_METHOD: nohttps
|
|
||||||
@ -1,16 +0,0 @@
|
|||||||
import pytest
|
|
||||||
import re
|
|
||||||
|
|
||||||
def test_loadbalance_hash(docker_compose, nginxproxy):
|
|
||||||
conf = nginxproxy.get_conf().decode('ASCII')
|
|
||||||
r1 = nginxproxy.get("http://loadbalance-enabled.nginx-proxy.tld")
|
|
||||||
r2 = nginxproxy.get("http://loadbalance-enabled.nginx-proxy.tld")
|
|
||||||
assert re.search(r"hash \$remote_addr\;", conf)
|
|
||||||
assert r1.status_code == 200
|
|
||||||
assert r2.text == r1.text
|
|
||||||
|
|
||||||
def test_loadbalance_roundrobin(docker_compose, nginxproxy):
|
|
||||||
r1 = nginxproxy.get("http://loadbalance-disabled.nginx-proxy.tld")
|
|
||||||
r2 = nginxproxy.get("http://loadbalance-disabled.nginx-proxy.tld")
|
|
||||||
assert r1.status_code == 200
|
|
||||||
assert r2.text != r1.text
|
|
||||||
@ -1,27 +0,0 @@
|
|||||||
services:
|
|
||||||
loadbalance-hash:
|
|
||||||
image: web
|
|
||||||
expose:
|
|
||||||
- "81"
|
|
||||||
environment:
|
|
||||||
WEB_PORTS: 81
|
|
||||||
VIRTUAL_HOST: loadbalance-enabled.nginx-proxy.tld
|
|
||||||
labels:
|
|
||||||
com.github.nginx-proxy.nginx-proxy.loadbalance: "hash $$remote_addr;"
|
|
||||||
deploy:
|
|
||||||
replicas: 2
|
|
||||||
|
|
||||||
loadbalance-roundrobin:
|
|
||||||
image: web
|
|
||||||
expose:
|
|
||||||
- "82"
|
|
||||||
environment:
|
|
||||||
WEB_PORTS: 82
|
|
||||||
VIRTUAL_HOST: loadbalance-disabled.nginx-proxy.tld
|
|
||||||
deploy:
|
|
||||||
replicas: 2
|
|
||||||
|
|
||||||
sut:
|
|
||||||
image: nginxproxy/nginx-proxy:test
|
|
||||||
volumes:
|
|
||||||
- /var/run/docker.sock:/tmp/docker.sock:ro
|
|
||||||
@ -1,39 +0,0 @@
|
|||||||
def test_explicit_root_nohash(docker_compose, nginxproxy):
|
|
||||||
r = nginxproxy.get("http://explicit-root-nohash.nginx-proxy.test/port")
|
|
||||||
assert r.status_code == 418
|
|
||||||
r = nginxproxy.get("http://explicit-root-nohash.nginx-proxy.test/foo/port")
|
|
||||||
assert r.status_code == 200
|
|
||||||
assert r.text == "answer from port 82\n"
|
|
||||||
|
|
||||||
def test_explicit_root_hash(docker_compose, nginxproxy):
|
|
||||||
r = nginxproxy.get("http://explicit-root-hash.nginx-proxy.test/port")
|
|
||||||
assert r.status_code == 418
|
|
||||||
r = nginxproxy.get("http://explicit-root-hash.nginx-proxy.test/foo/port")
|
|
||||||
assert r.status_code == 200
|
|
||||||
assert r.text == "answer from port 82\n"
|
|
||||||
|
|
||||||
def test_explicit_root_hash_and_nohash(docker_compose, nginxproxy):
|
|
||||||
r = nginxproxy.get("http://explicit-root-hash-and-nohash.nginx-proxy.test/port")
|
|
||||||
assert r.status_code == 418
|
|
||||||
r = nginxproxy.get("http://explicit-root-hash-and-nohash.nginx-proxy.test/foo/port")
|
|
||||||
assert r.status_code == 200
|
|
||||||
assert r.text == "answer from port 82\n"
|
|
||||||
|
|
||||||
def test_explicit_nonroot(docker_compose, nginxproxy):
|
|
||||||
r = nginxproxy.get("http://explicit-nonroot.nginx-proxy.test/port")
|
|
||||||
assert r.status_code == 200
|
|
||||||
assert r.text == "answer from port 81\n"
|
|
||||||
r = nginxproxy.get("http://explicit-nonroot.nginx-proxy.test/foo/port")
|
|
||||||
assert r.status_code == 418
|
|
||||||
|
|
||||||
def test_implicit_root_nohash(docker_compose, nginxproxy):
|
|
||||||
r = nginxproxy.get("http://implicit-root-nohash.nginx-proxy.test/port")
|
|
||||||
assert r.status_code == 418
|
|
||||||
|
|
||||||
def test_implicit_root_hash(docker_compose, nginxproxy):
|
|
||||||
r = nginxproxy.get("http://implicit-root-hash.nginx-proxy.test/port")
|
|
||||||
assert r.status_code == 418
|
|
||||||
|
|
||||||
def test_implicit_root_hash_and_nohash(docker_compose, nginxproxy):
|
|
||||||
r = nginxproxy.get("http://implicit-root-hash-and-nohash.nginx-proxy.test/port")
|
|
||||||
assert r.status_code == 418
|
|
||||||
@ -1,3 +0,0 @@
|
|||||||
location /foo/ {
|
|
||||||
return 418;
|
|
||||||
}
|
|
||||||
@ -1,4 +0,0 @@
|
|||||||
# This file should trump the file without the hash.
|
|
||||||
location / {
|
|
||||||
return 418;
|
|
||||||
}
|
|
||||||
@ -1,4 +0,0 @@
|
|||||||
# The file with the hash should trump this file.
|
|
||||||
location / {
|
|
||||||
return 503;
|
|
||||||
}
|
|
||||||
@ -1,3 +0,0 @@
|
|||||||
location / {
|
|
||||||
return 418;
|
|
||||||
}
|
|
||||||
@ -1,3 +0,0 @@
|
|||||||
location / {
|
|
||||||
return 418;
|
|
||||||
}
|
|
||||||
@ -1,4 +0,0 @@
|
|||||||
# This file should trump the file without the hash.
|
|
||||||
location / {
|
|
||||||
return 418;
|
|
||||||
}
|
|
||||||
@ -1,4 +0,0 @@
|
|||||||
# The file with the hash should trump this file.
|
|
||||||
location / {
|
|
||||||
return 503;
|
|
||||||
}
|
|
||||||
@ -1,3 +0,0 @@
|
|||||||
location / {
|
|
||||||
return 418;
|
|
||||||
}
|
|
||||||
@ -1,3 +0,0 @@
|
|||||||
location / {
|
|
||||||
return 418;
|
|
||||||
}
|
|
||||||
@ -1,44 +0,0 @@
|
|||||||
services:
|
|
||||||
sut:
|
|
||||||
image: nginxproxy/nginx-proxy:test
|
|
||||||
volumes:
|
|
||||||
- /var/run/docker.sock:/tmp/docker.sock:ro
|
|
||||||
- ./test_location-override.vhost.d:/etc/nginx/vhost.d:ro
|
|
||||||
|
|
||||||
explicit-root:
|
|
||||||
image: web
|
|
||||||
expose:
|
|
||||||
- "81"
|
|
||||||
environment:
|
|
||||||
WEB_PORTS: "81"
|
|
||||||
VIRTUAL_HOST: >-
|
|
||||||
explicit-root-nohash.nginx-proxy.test,
|
|
||||||
explicit-root-hash.nginx-proxy.test,
|
|
||||||
explicit-root-hash-and-nohash.nginx-proxy.test,
|
|
||||||
explicit-nonroot.nginx-proxy.test
|
|
||||||
VIRTUAL_PATH: /
|
|
||||||
explicit-foo:
|
|
||||||
image: web
|
|
||||||
expose:
|
|
||||||
- "82"
|
|
||||||
environment:
|
|
||||||
WEB_PORTS: "82"
|
|
||||||
VIRTUAL_HOST: >-
|
|
||||||
explicit-root-nohash.nginx-proxy.test,
|
|
||||||
explicit-root-hash.nginx-proxy.test,
|
|
||||||
explicit-root-hash-and-nohash.nginx-proxy.test,
|
|
||||||
explicit-nonroot.nginx-proxy.test
|
|
||||||
VIRTUAL_PATH: /foo/
|
|
||||||
VIRTUAL_DEST: /
|
|
||||||
|
|
||||||
# Same as explicit-root except VIRTUAL_PATH is left unset.
|
|
||||||
implicit-root:
|
|
||||||
image: web
|
|
||||||
expose:
|
|
||||||
- "83"
|
|
||||||
environment:
|
|
||||||
WEB_PORTS: "83"
|
|
||||||
VIRTUAL_HOST: >-
|
|
||||||
implicit-root-nohash.nginx-proxy.test,
|
|
||||||
implicit-root-hash.nginx-proxy.test,
|
|
||||||
implicit-root-hash-and-nohash.nginx-proxy.test,
|
|
||||||
@ -1,11 +0,0 @@
|
|||||||
import pytest
|
|
||||||
|
|
||||||
def test_log_format(docker_compose, nginxproxy):
|
|
||||||
r = nginxproxy.get("http://nginx-proxy.test/port")
|
|
||||||
assert r.status_code == 200
|
|
||||||
assert r.text == "answer from port 81\n"
|
|
||||||
sut_container = docker_compose.containers.get("sut")
|
|
||||||
docker_logs = sut_container.logs(stdout=True, stderr=True, stream=False, follow=False)
|
|
||||||
docker_logs = docker_logs.decode("utf-8").splitlines()
|
|
||||||
docker_logs = [line for line in docker_logs if "GET /port" in line]
|
|
||||||
assert "request_time=" in docker_logs[0]
|
|
||||||
@ -1,15 +0,0 @@
|
|||||||
web1:
|
|
||||||
image: web
|
|
||||||
expose:
|
|
||||||
- "81"
|
|
||||||
environment:
|
|
||||||
WEB_PORTS: 81
|
|
||||||
VIRTUAL_HOST: nginx-proxy.test
|
|
||||||
|
|
||||||
sut:
|
|
||||||
container_name: sut
|
|
||||||
image: nginxproxy/nginx-proxy:test
|
|
||||||
volumes:
|
|
||||||
- /var/run/docker.sock:/tmp/docker.sock:ro
|
|
||||||
environment:
|
|
||||||
LOG_FORMAT: "$$remote_addr - $$remote_user [$$time_local] \"$$request\" $$status $$body_bytes_sent \"$$http_referer\" \"$$http_user_agent\" request_time=$$request_time $$upstream_response_time"
|
|
||||||
@ -1,28 +1,15 @@
|
|||||||
import re
|
|
||||||
|
|
||||||
import pytest
|
import pytest
|
||||||
|
|
||||||
|
|
||||||
def test_unknown_virtual_host(docker_compose, nginxproxy):
|
def test_unknown_virtual_host(docker_compose, nginxproxy):
|
||||||
r = nginxproxy.get("http://nginx-proxy/")
|
r = nginxproxy.get("http://nginx-proxy/")
|
||||||
assert r.status_code == 503
|
assert r.status_code == 503
|
||||||
|
|
||||||
def test_forwards_to_web1(docker_compose, nginxproxy):
|
def test_forwards_to_web1(docker_compose, nginxproxy):
|
||||||
r = nginxproxy.get("http://web1.nginx-proxy.local/port")
|
r = nginxproxy.get("http://web1.nginx-proxy.local/port")
|
||||||
assert r.status_code == 200
|
assert r.status_code == 200
|
||||||
assert r.text == "answer from port 81\n"
|
assert r.text == "answer from port 81\n"
|
||||||
|
|
||||||
def test_forwards_to_web2(docker_compose, nginxproxy):
|
def test_forwards_to_web2(docker_compose, nginxproxy):
|
||||||
r = nginxproxy.get("http://web2.nginx-proxy.local/port")
|
r = nginxproxy.get("http://web2.nginx-proxy.local/port")
|
||||||
assert r.status_code == 200
|
assert r.status_code == 200
|
||||||
assert r.text == "answer from port 82\n"
|
assert r.text == "answer from port 82\n"
|
||||||
|
|
||||||
def test_multipath(docker_compose, nginxproxy):
|
|
||||||
r = nginxproxy.get("http://web3.nginx-proxy.test/port")
|
|
||||||
assert r.status_code == 200
|
|
||||||
assert r.text == "answer from port 83\n"
|
|
||||||
cfg = nginxproxy.get_conf().decode()
|
|
||||||
lines = cfg.splitlines()
|
|
||||||
web3_server_lines = [l for l in lines
|
|
||||||
if re.search(r'(?m)^\s*server\s+[^\s]*:83;\s*$', l)]
|
|
||||||
assert len(web3_server_lines) == 1
|
|
||||||
@ -3,8 +3,6 @@ version: '2'
|
|||||||
networks:
|
networks:
|
||||||
net1: {}
|
net1: {}
|
||||||
net2: {}
|
net2: {}
|
||||||
net3a: {}
|
|
||||||
net3b: {}
|
|
||||||
|
|
||||||
services:
|
services:
|
||||||
nginx-proxy:
|
nginx-proxy:
|
||||||
@ -14,8 +12,6 @@ services:
|
|||||||
networks:
|
networks:
|
||||||
- net1
|
- net1
|
||||||
- net2
|
- net2
|
||||||
- net3a
|
|
||||||
- net3b
|
|
||||||
|
|
||||||
web1:
|
web1:
|
||||||
image: web
|
image: web
|
||||||
@ -36,14 +32,3 @@ services:
|
|||||||
VIRTUAL_HOST: web2.nginx-proxy.local
|
VIRTUAL_HOST: web2.nginx-proxy.local
|
||||||
networks:
|
networks:
|
||||||
- net2
|
- net2
|
||||||
|
|
||||||
web3:
|
|
||||||
image: web
|
|
||||||
expose:
|
|
||||||
- "83"
|
|
||||||
environment:
|
|
||||||
WEB_PORTS: 83
|
|
||||||
VIRTUAL_HOST: web3.nginx-proxy.test
|
|
||||||
networks:
|
|
||||||
- net3a
|
|
||||||
- net3b
|
|
||||||
|
|||||||
@ -1,5 +1,6 @@
|
|||||||
import re
|
import re
|
||||||
import subprocess
|
import subprocess
|
||||||
|
import os
|
||||||
|
|
||||||
import backoff
|
import backoff
|
||||||
import docker
|
import docker
|
||||||
@ -218,7 +219,7 @@ def test_custom_dhparam_is_supported(docker_compose):
|
|||||||
|
|
||||||
# Only `web2` has a site-specific DH param file (which overrides all other DH config)
|
# Only `web2` has a site-specific DH param file (which overrides all other DH config)
|
||||||
# Other tests here use `web5` explicitly, or implicitly (via ENV `DEFAULT_HOST`, otherwise first HTTPS server)
|
# Other tests here use `web5` explicitly, or implicitly (via ENV `DEFAULT_HOST`, otherwise first HTTPS server)
|
||||||
def test_custom_dhparam_is_supported_per_site(docker_compose, ca_root_certificate):
|
def test_custom_dhparam_is_supported_per_site(docker_compose):
|
||||||
container_name="dh-file"
|
container_name="dh-file"
|
||||||
sut_container = docker_client.containers.get(container_name)
|
sut_container = docker_client.containers.get(container_name)
|
||||||
assert sut_container.status == "running"
|
assert sut_container.status == "running"
|
||||||
@ -241,7 +242,7 @@ def test_custom_dhparam_is_supported_per_site(docker_compose, ca_root_certificat
|
|||||||
# - `web2` has it's own cert provisioned at `/etc/nginx/certs/web2.nginx-proxy.tld.crt`.
|
# - `web2` has it's own cert provisioned at `/etc/nginx/certs/web2.nginx-proxy.tld.crt`.
|
||||||
can_verify_chain_of_trust(
|
can_verify_chain_of_trust(
|
||||||
sut_container,
|
sut_container,
|
||||||
ca_cert = ca_root_certificate,
|
ca_cert = f"{os.getcwd()}/certs/ca-root.crt",
|
||||||
fqdn = 'web2.nginx-proxy.tld'
|
fqdn = 'web2.nginx-proxy.tld'
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|||||||
@ -1,10 +1,9 @@
|
|||||||
import pytest
|
import pytest
|
||||||
import requests
|
|
||||||
|
|
||||||
|
|
||||||
def test_web2_http_is_connection_refused(docker_compose, nginxproxy):
|
def test_web2_http_is_not_forwarded(docker_compose, nginxproxy):
|
||||||
with pytest.raises(requests.exceptions.RequestException, match="Connection refused"):
|
r = nginxproxy.get("http://web2.nginx-proxy.tld/", allow_redirects=False)
|
||||||
nginxproxy.get("http://web2.nginx-proxy.tld/")
|
assert r.status_code == 503
|
||||||
|
|
||||||
|
|
||||||
def test_web2_https_is_forwarded(docker_compose, nginxproxy):
|
def test_web2_https_is_forwarded(docker_compose, nginxproxy):
|
||||||
|
|||||||
@ -24,10 +24,10 @@ def test_https_get_served(docker_compose, nginxproxy, subdomain):
|
|||||||
assert f"answer from port 8{subdomain}\n" == r.text
|
assert f"answer from port 8{subdomain}\n" == r.text
|
||||||
|
|
||||||
@pytest.mark.filterwarnings('ignore::urllib3.exceptions.InsecureRequestWarning')
|
@pytest.mark.filterwarnings('ignore::urllib3.exceptions.InsecureRequestWarning')
|
||||||
def test_https_request_to_nohttps_vhost_goes_to_fallback_server(docker_compose, nginxproxy):
|
def test_web3_https_is_500_and_SSL_validation_fails(docker_compose, nginxproxy):
|
||||||
with pytest.raises( (CertificateError, SSLError) ) as excinfo:
|
with pytest.raises( (CertificateError, SSLError) ) as excinfo:
|
||||||
nginxproxy.get("https://3.web.nginx-proxy.tld/port")
|
nginxproxy.get("https://3.web.nginx-proxy.tld/port")
|
||||||
assert """hostname '3.web.nginx-proxy.tld' doesn't match 'nginx-proxy.tld'""" in str(excinfo.value)
|
assert """hostname '3.web.nginx-proxy.tld' doesn't match 'nginx-proxy.tld'""" in str(excinfo.value)
|
||||||
|
|
||||||
r = nginxproxy.get("https://3.web.nginx-proxy.tld/port", verify=False)
|
r = nginxproxy.get("https://3.web.nginx-proxy.tld/port", verify=False)
|
||||||
assert r.status_code == 503
|
assert r.status_code == 500
|
||||||
|
|||||||
@ -1,10 +0,0 @@
|
|||||||
import re
|
|
||||||
|
|
||||||
|
|
||||||
def test_vhost_empty_string(docker_compose, nginxproxy):
|
|
||||||
conf = nginxproxy.get_conf().decode()
|
|
||||||
assert re.search(r"(?m)^\s*server_name\s+web2\.nginx-proxy\.test\s*;", conf)
|
|
||||||
assert re.search(r"(?m)^\s*server_name\s+web3\.nginx-proxy\.test\s*;", conf)
|
|
||||||
assert re.search(r"(?m)^\s*server_name\s+web4a\.nginx-proxy\.test\s*;", conf)
|
|
||||||
assert re.search(r"(?m)^\s*server_name\s+web4b\.nginx-proxy\.test\s*;", conf)
|
|
||||||
assert not re.search(r"(?m)^\s*server_name\s*;", conf)
|
|
||||||
@ -1,37 +0,0 @@
|
|||||||
services:
|
|
||||||
sut:
|
|
||||||
image: nginxproxy/nginx-proxy:test
|
|
||||||
volumes:
|
|
||||||
- /var/run/docker.sock:/tmp/docker.sock:ro
|
|
||||||
web1:
|
|
||||||
image: web
|
|
||||||
expose:
|
|
||||||
- "81"
|
|
||||||
environment:
|
|
||||||
WEB_PORTS: "81"
|
|
||||||
# The space is intentional (should be trimmed).
|
|
||||||
VIRTUAL_HOST: " "
|
|
||||||
web2:
|
|
||||||
image: web
|
|
||||||
expose:
|
|
||||||
- "82"
|
|
||||||
environment:
|
|
||||||
WEB_PORTS: "82"
|
|
||||||
# The space is intentional (should be trimmed).
|
|
||||||
VIRTUAL_HOST: "web2.nginx-proxy.test ,"
|
|
||||||
web3:
|
|
||||||
image: web
|
|
||||||
expose:
|
|
||||||
- "83"
|
|
||||||
environment:
|
|
||||||
WEB_PORTS: "83"
|
|
||||||
# The space is intentional (should be trimmed).
|
|
||||||
VIRTUAL_HOST: " ,web3.nginx-proxy.test"
|
|
||||||
web4:
|
|
||||||
image: web
|
|
||||||
expose:
|
|
||||||
- "84"
|
|
||||||
environment:
|
|
||||||
WEB_PORTS: "84"
|
|
||||||
# The spaces are intentional (should be trimmed).
|
|
||||||
VIRTUAL_HOST: "web4a.nginx-proxy.test, , web4b.nginx-proxy.test"
|
|
||||||
Loading…
Reference in New Issue
Block a user