diff --git a/.coverage.8674b3a12c0a.9.XzQXStzx b/.coverage.8674b3a12c0a.9.XzQXStzx deleted file mode 100644 index 820c9db8ab..0000000000 Binary files a/.coverage.8674b3a12c0a.9.XzQXStzx and /dev/null differ diff --git a/Makefile b/Makefile index 1a15bac4fe..f4c088c1b8 100644 --- a/Makefile +++ b/Makefile @@ -47,7 +47,7 @@ DEV_CREATE_OEREBLEX_TABLES_SCRIPT = $(VENV_BIN)/create_oereblex_tables MODEL_PK_TYPE_IS_STRING ?= true -PRINT_URL ?= http://svamaa-print-1:8080/print/oereb +PRINT_URL ?= http://oereb-print:8080/print/oereb # ******************** # Variable definitions diff --git a/dev/config/create_yaml.py b/dev/config/create_yaml.py index ac54837021..d53911c5f7 100644 --- a/dev/config/create_yaml.py +++ b/dev/config/create_yaml.py @@ -8,7 +8,7 @@ def _create_yaml_config_( name='pyramid_oereb.yml', database='postgresql://postgres:password@localhost/pyramid_oereb', - print_url='http://svamaa-print-1:8080/print/oereb'): + print_url='http://oereb-print:8080/print/oereb'): """ Creates the specified YAML file using a template. This YAML file contains the standard configuration to run a oereb server out of the box. @@ -61,7 +61,7 @@ def create_yaml(): dest='print_url', metavar='PRINT_URL', type='string', - default='http://svamaa-print-1:8080/print/oereb', + default='http://oereb-print:8080/print/oereb', help='The URL of the print server' ) options, args = parser.parse_args() diff --git a/development.ini.mako b/development.ini.mako index ae366a6792..1d8133082f 100644 --- a/development.ini.mako +++ b/development.ini.mako @@ -14,16 +14,6 @@ pyramid.default_locale_name = en pyramid_oereb.cfg.file = %(here)s/pyramid_oereb.yml pyramid_oereb.cfg.section = pyramid_oereb -# Enable debug toolbar -pyramid.includes = pyramid_debugtoolbar -debugtoolbar.hosts = 0.0.0.0/0 -debugtoolbar.enabled = true -debugtoolbar.intercept_exc = display -debugtoolbar.max_request_history = 100 -debugtoolbar.panels = headers logging performance renderings - request_vars sqlalchemy traceback - - sqlalchemy.url = sqlite:///%(here)s/pyramid_oereb.sqlite ### diff --git a/pyramid_oereb/core/views/webservice.py b/pyramid_oereb/core/views/webservice.py index 2d610d9a7f..2b8ecfbc05 100644 --- a/pyramid_oereb/core/views/webservice.py +++ b/pyramid_oereb/core/views/webservice.py @@ -625,13 +625,13 @@ def __response_compression__(self, response): pyramid.response.Response: The response. """ - if 'ACCEPT_ENCODING' in self._request.headers: - if 'br' in self._request.headers['ACCEPT_ENCODING']: + if 'Accept-Encoding' in self._request.headers: + if 'br' in self._request.headers['Accept-Encoding']: response.content_encoding = 'br' compressed_response = brotli.compress(response.body) response.content_length = str(len(compressed_response)) response.body = compressed_response - elif 'gzip' in self._request.headers['ACCEPT_ENCODING']: + elif 'gzip' in self._request.headers['Accept-Encoding']: response.content_encoding = 'gzip' gzip_buffer = io.BytesIO() with gzip.GzipFile(mode='wb', fileobj=gzip_buffer) as gzip_file: