so I can access both node1 and node2, I use the env variable with export as you do in your guide but I still got this error when trying to fectch remote library :
Could not fetch remote library
Error while fetching the library: HTTPSConnectionPool(host='node1.funkwhale.test', port=443): Max retries exceeded with url: /federation/music/libraries/7011a4c9-2a66-49eb-a66f-ae51769a519f (Caused by NewConnectionError('<urllib3.connection.HTTPSConnection object at 0x7f86ec6f4340>: Failed to establish a new connection: [Errno 111] Connection refused'))
instance sending request :
node2-api-1 | 2022-04-15 14:23:40,424 django.request WARNING Bad Request: /api/v1/federation/libraries/fetch/
node2-api-1 | INFO: 172.20.0.7:48128 - "POST /api/v1/federation/libraries/fetch/ HTTP/1.1" 400 Bad Request
node2-nginx-1 | 172.21.0.3 - - [15/Apr/2022:14:23:40 +0000] "POST /api/v1/federation/libraries/fetch/ HTTP/1.1" 400 368 "https://node2.funkwhale.test/content/remote/" "Mozilla/5.0 (X11; Ubuntu; Linux x86_64; rv:99.0) Gecko/20100101 Firefox/99.0" "172.21.0.1"
instance receiving : nothing
traefik :
docker-traefik-1 | 172.21.0.1 - - [15/Apr/2022:14:27:33 +0000] "POST /api/v1/federation/libraries/fetch/ HTTP/2.0" 400 368 "https://node2.funkwhale.test/content/remote/" "Mozilla/5.0 (X11; Ubuntu; Linux x86_64; rv:99.0) Gecko/20100101 Firefox/99.0" 646 "federation-nginx-node2-node2" "http://172.21.0.4:80" 29ms
In node1 I have this error but not in node2 :
172.21.0.3 - - [15/Apr/2022:14:51:27 +0000] "GET /api/v1/activity?token=null HTTP/1.1" 403 0 "-" "Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/97.0.4692.20 Safari/537.36" "-"
node1-api-1 | INFO: connection closed
node1-api-1 | 2022-04-15 14:51:27,931 uvicorn.error INFO connection closed
node1-api-1 | ERROR: Exception in ASGI application
node1-api-1 | Traceback (most recent call last):
node1-api-1 | File "/venv/lib/python3.9/site-packages/uvicorn/protocols/websockets/websockets_impl.py", line 184, in run_asgi
node1-api-1 | result = await self.app(self.scope, self.asgi_receive, self.asgi_send)
node1-api-1 | File "/venv/lib/python3.9/site-packages/uvicorn/middleware/proxy_headers.py", line 75, in __call__
node1-api-1 | return await self.app(scope, receive, send)
node1-api-1 | File "/venv/lib/python3.9/site-packages/channels/routing.py", line 71, in __call__
node1-api-1 | return await application(scope, receive, send)
node1-api-1 | File "/venv/lib/python3.9/site-packages/channels/sessions.py", line 47, in __call__
node1-api-1 | return await self.inner(dict(scope, cookies=cookies), receive, send)
node1-api-1 | File "/venv/lib/python3.9/site-packages/channels/sessions.py", line 263, in __call__
node1-api-1 | return await self.inner(wrapper.scope, receive, wrapper.send)
node1-api-1 | File "/venv/lib/python3.9/site-packages/channels/auth.py", line 185, in __call__
node1-api-1 | return await super().__call__(scope, receive, send)
node1-api-1 | File "/venv/lib/python3.9/site-packages/channels/middleware.py", line 26, in __call__
node1-api-1 | return await self.inner(scope, receive, send)
node1-api-1 | File "/venv/lib/python3.9/site-packages/channels/routing.py", line 150, in __call__
node1-api-1 | return await application(
node1-api-1 | File "/venv/lib/python3.9/site-packages/channels/consumer.py", line 94, in app
node1-api-1 | return await consumer(scope, receive, send)
node1-api-1 | File "/venv/lib/python3.9/site-packages/channels/consumer.py", line 58, in __call__
node1-api-1 | await await_many_dispatch(
node1-api-1 | File "/venv/lib/python3.9/site-packages/channels/utils.py", line 51, in await_many_dispatch
node1-api-1 | await dispatch(result)
node1-api-1 | File "/venv/lib/python3.9/site-packages/asgiref/sync.py", line 414, in __call__
node1-api-1 | ret = await asyncio.wait_for(future, timeout=None)
node1-api-1 | File "/usr/lib/python3.9/asyncio/tasks.py", line 442, in wait_for
node1-api-1 | return await fut
node1-api-1 | File "/usr/lib/python3.9/concurrent/futures/thread.py", line 52, in run
node1-api-1 | result = self.fn(*self.args, **self.kwargs)
node1-api-1 | File "/venv/lib/python3.9/site-packages/channels/db.py", line 13, in thread_handler
node1-api-1 | return super().thread_handler(loop, *args, **kwargs)
node1-api-1 | File "/venv/lib/python3.9/site-packages/asgiref/sync.py", line 455, in thread_handler
node1-api-1 | return func(*args, **kwargs)
node1-api-1 | File "/venv/lib/python3.9/site-packages/channels/consumer.py", line 125, in dispatch
node1-api-1 | handler(message)
node1-api-1 | File "/venv/lib/python3.9/site-packages/channels/generic/websocket.py", line 105, in websocket_disconnect
node1-api-1 | self.disconnect(message["code"])
node1-api-1 | File "/app/./funkwhale_api/common/consumers.py", line 22, in disconnect
node1-api-1 | groups = self.scope["user"].get_channels_groups() + self.groups
node1-api-1 | File "/venv/lib/python3.9/site-packages/django/utils/functional.py", line 247, in inner
node1-api-1 | return func(self._wrapped, *args)
node1-api-1 | AttributeError: 'AnonymousUser' object has no attribute 'get_channels_groups'