I have a strange issue: I have a multi container docker setup that first ran on the previous stable versions (1.1.4), then I changed it to use FUNKWHALE_VERSION=develop
and frequently updated it to the latest develop version. Currently it happily runs with 1.2.0+git.742f843c which at time of writing this is the latest commit on develop that bumps the version to 1.2.0.
Now if I switch to FUNKWHALE_VERSION=1.2.0
and update the containers Fukwhale fails to serve any request. The funkwhale_api_1 container gives the following error:
[2022-01-01 13:02:57 +0000] [12] [INFO] Application startup complete.
2022-01-01 13:04:05,077 plugins DEBUG Calling handlers for filter urls
2022-01-01 13:04:05,587 django.request ERROR Internal Server Error: /about/pod
Traceback (most recent call last):
File "/venv/lib/python3.8/site-packages/urllib3/connection.py", line 174, in _new_conn
conn = connection.create_connection(
File "/venv/lib/python3.8/site-packages/urllib3/util/connection.py", line 96, in create_connection
raise err
File "/venv/lib/python3.8/site-packages/urllib3/util/connection.py", line 86, in create_connection
sock.connect(sa)
ConnectionRefusedError: [Errno 111] Connection refused
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/venv/lib/python3.8/site-packages/urllib3/connectionpool.py", line 699, in urlopen
httplib_response = self._make_request(
File "/venv/lib/python3.8/site-packages/urllib3/connectionpool.py", line 382, in _make_request
self._validate_conn(conn)
File "/venv/lib/python3.8/site-packages/urllib3/connectionpool.py", line 1010, in _validate_conn
conn.connect()
File "/venv/lib/python3.8/site-packages/urllib3/connection.py", line 358, in connect
conn = self._new_conn()
File "/venv/lib/python3.8/site-packages/urllib3/connection.py", line 186, in _new_conn
raise NewConnectionError(
urllib3.exceptions.NewConnectionError: <urllib3.connection.HTTPSConnection object at 0x7f5ea5469610>: Failed to establish a new connection: [Errno 111] Connection refused
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/venv/lib/python3.8/site-packages/requests/adapters.py", line 439, in send
resp = conn.urlopen(
File "/venv/lib/python3.8/site-packages/urllib3/connectionpool.py", line 755, in urlopen
retries = retries.increment(
File "/venv/lib/python3.8/site-packages/urllib3/util/retry.py", line 574, in increment
raise MaxRetryError(_pool, url, error or ResponseError(cause))
urllib3.exceptions.MaxRetryError: HTTPSConnectionPool(host='music.uploadedlobster.com', port=443): Max retries exceeded with url: /front/index.html (Caused by NewConnectionError('<urllib3.connection.HTTPSConnection object at 0x7f5ea5469610>: Failed to establish a new connection: [Errno 111] Connection refused'))
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/venv/lib/python3.8/site-packages/django/core/handlers/exception.py", line 47, in inner
response = get_response(request)
File "/app/funkwhale_api/common/middleware.py", line 239, in __call__
return serve_spa(request)
File "/app/funkwhale_api/common/middleware.py", line 38, in serve_spa
html = get_spa_html(settings.FUNKWHALE_SPA_HTML_ROOT)
File "/app/funkwhale_api/common/middleware.py", line 112, in get_spa_html
return get_spa_file(spa_url, "index.html")
File "/app/funkwhale_api/common/middleware.py", line 129, in get_spa_file
response = session.get_session().get(utils.join_url(spa_url, name),)
File "/venv/lib/python3.8/site-packages/requests/sessions.py", line 555, in get
return self.request('GET', url, **kwargs)
File "/app/funkwhale_api/common/session.py", line 11, in request
return super().request(*args, **kwargs)
File "/venv/lib/python3.8/site-packages/requests/sessions.py", line 542, in request
resp = self.send(prep, **send_kwargs)
File "/venv/lib/python3.8/site-packages/requests/sessions.py", line 655, in send
r = adapter.send(request, **kwargs)
File "/venv/lib/python3.8/site-packages/requests/adapters.py", line 516, in send
raise ConnectionError(e, request=request)
requests.exceptions.ConnectionError: HTTPSConnectionPool(host='music.uploadedlobster.com', port=443): Max retries exceeded with url: /front/index.html (Caused by NewConnectionError('<urllib3.connection.HTTPSConnection object at 0x7f5ea5469610>: Failed to establish a new connection: [Errno 111] Connection refused'))
So something seems to be different for how the stable images are behaving compared to develop. But it is not clear what it is.
Maybe part of the issue is that the nginx that is part of the multi container funkwhale setup in my configuration does not do the HTTPS handling. Instead there is another nginx proxy that provides the SSL certificates for multiple docker based services on the same server (based on the setup at https://github.com/phw/docker-nginx-proxy-letsencrypt). But still I don't see how this should matter and why the develop version runs just fine.