Skip to content

Current Docker image isn't working #484

@smileart

Description

@smileart

Environment:

  • macOS High Sierra 10.13.5
  • Docker community edition (Version 18.03.1-ce-mac65 (24312))
  • kennethreitz/httpbin, latest, 2 days ago

How to reproduce:

docker run -p 80:80 kennethreitz/httpbin

Request http://localhost:80 in browser. Which leaves us with an error:

Internal Server Error

The server encountered an internal error and was unable to complete your request. Either the server is overloaded or there is an error in the application.

And logs in the terminal:

[2018-07-06 14:12:08 +0000] [1] [INFO] Starting gunicorn 19.9.0
[2018-07-06 14:12:08 +0000] [1] [INFO] Listening at: http://0.0.0.0:80 (1)
[2018-07-06 14:12:08 +0000] [1] [INFO] Using worker: gevent
[2018-07-06 14:12:08 +0000] [10] [INFO] Booting worker with pid: 10
[2018-07-06 14:12:13,137] ERROR in app: Exception on / [GET]
Traceback (most recent call last):
  File "/usr/local/lib/python3.6/dist-packages/flask/app.py", line 2292, in wsgi_app
    response = self.full_dispatch_request()
  File "/usr/local/lib/python3.6/dist-packages/flask/app.py", line 1815, in full_dispatch_request
    rv = self.handle_user_exception(e)
  File "/usr/local/lib/python3.6/dist-packages/flask/app.py", line 1718, in handle_user_exception
    reraise(exc_type, exc_value, tb)
  File "/usr/local/lib/python3.6/dist-packages/flask/_compat.py", line 35, in reraise
    raise value
  File "/usr/local/lib/python3.6/dist-packages/flask/app.py", line 1813, in full_dispatch_request
    rv = self.dispatch_request()
  File "/usr/local/lib/python3.6/dist-packages/flask/app.py", line 1799, in dispatch_request
    return self.view_functions[rule.endpoint](**req.view_args)
  File "/usr/local/lib/python3.6/dist-packages/flask/views.py", line 88, in view
    return self.dispatch_request(*args, **kwargs)
  File "/usr/local/lib/python3.6/dist-packages/flask/views.py", line 158, in dispatch_request
    return meth(*args, **kwargs)
  File "/usr/local/lib/python3.6/dist-packages/flasgger/base.py", line 85, in get
    **data
  File "/usr/local/lib/python3.6/dist-packages/flask/templating.py", line 134, in render_template
    return _render(ctx.app.jinja_env.get_or_select_template(template_name_or_list),
  File "/usr/local/lib/python3.6/dist-packages/jinja2/environment.py", line 869, in get_or_select_template
    return self.get_template(template_name_or_list, parent, globals)
  File "/usr/local/lib/python3.6/dist-packages/jinja2/environment.py", line 830, in get_template
    return self._load_template(name, self.make_globals(globals))
  File "/usr/local/lib/python3.6/dist-packages/jinja2/environment.py", line 804, in _load_template
    template = self.loader.load(self, name, globals)
  File "/usr/local/lib/python3.6/dist-packages/jinja2/loaders.py", line 125, in load
    code = environment.compile(source, name, filename)
  File "/usr/local/lib/python3.6/dist-packages/jinja2/environment.py", line 591, in compile
    self.handle_exception(exc_info, source_hint=source_hint)
  File "/usr/local/lib/python3.6/dist-packages/jinja2/environment.py", line 780, in handle_exception
    reraise(exc_type, exc_value, tb)
  File "/usr/local/lib/python3.6/dist-packages/jinja2/_compat.py", line 37, in reraise
    raise value.with_traceback(tb)
  File "/usr/local/lib/python3.6/dist-packages/httpbin/templates/flasgger/index.html", line 147, in template
    {% - endif %}
  File "/usr/local/lib/python3.6/dist-packages/jinja2/environment.py", line 497, in _parse
    return Parser(self, source, name, encode_filename(filename)).parse()
  File "/usr/local/lib/python3.6/dist-packages/jinja2/parser.py", line 901, in parse
    result = nodes.Template(self.subparse(), lineno=1)
  File "/usr/local/lib/python3.6/dist-packages/jinja2/parser.py", line 883, in subparse
    rv = self.parse_statement()
  File "/usr/local/lib/python3.6/dist-packages/jinja2/parser.py", line 130, in parse_statement
    return getattr(self, 'parse_' + self.stream.current.value)()
  File "/usr/local/lib/python3.6/dist-packages/jinja2/parser.py", line 213, in parse_if
    'name:endif'))
  File "/usr/local/lib/python3.6/dist-packages/jinja2/parser.py", line 165, in parse_statements
    result = self.subparse(end_tokens)
  File "/usr/local/lib/python3.6/dist-packages/jinja2/parser.py", line 883, in subparse
    rv = self.parse_statement()
  File "/usr/local/lib/python3.6/dist-packages/jinja2/parser.py", line 125, in parse_statement
    self.fail('tag name expected', token.lineno)
  File "/usr/local/lib/python3.6/dist-packages/jinja2/parser.py", line 59, in fail
    raise exc(msg, lineno, self.name, self.filename)
jinja2.exceptions.TemplateSyntaxError: tag name expected

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions