![Ubuntu 服务器中的 Docker + 音频](https://linux22.com/image/1031931/Ubuntu%20%E6%9C%8D%E5%8A%A1%E5%99%A8%E4%B8%AD%E7%9A%84%20Docker%20%2B%20%E9%9F%B3%E9%A2%91.png)
我正在努力ghcr.io/synesthesiam/homeassistant-satellite在我的 ubuntu 服务器上运行 docker 容器。我让它工作了,但它经常停止工作并出现以下错误:
ERROR:asyncio:Task exception was never retrieved
future: <Task finished name='Task-3054979' coro=<ClientWebSocketResponse.send_bytes() done, defined at /usr/local/lib/python3.11/site-packages/aiohttp/client_ws.py:153> exception=ConnectionResetError('Cannot write to closing transport')>
Traceback (most recent call last):
File "/usr/local/lib/python3.11/site-packages/aiohttp/client_ws.py", line 156, in send_bytes
await self._writer.send(data, binary=True, compress=compress)
File "/usr/local/lib/python3.11/site-packages/aiohttp/http_websocket.py", line 688, in send
await self._send_frame(message, WSMsgType.BINARY, compress)
File "/usr/local/lib/python3.11/site-packages/aiohttp/http_websocket.py", line 601, in _send_frame
raise ConnectionResetError("Cannot write to closing transport")
ConnectionResetError: Cannot write to closing transport
ERROR:asyncio:Task exception was never retrieved
future: <Task finished name='Task-3054981' coro=<ClientWebSocketResponse.send_bytes() done, defined at /usr/local/lib/python3.11/site-packages/aiohttp/client_ws.py:153> exception=ConnectionResetError('Cannot write to closing transport')>
Traceback (most recent call last):
File "/usr/local/lib/python3.11/site-packages/aiohttp/client_ws.py", line 156, in send_bytes
await self._writer.send(data, binary=True, compress=compress)
File "/usr/local/lib/python3.11/site-packages/aiohttp/http_websocket.py", line 688, in send
await self._send_frame(message, WSMsgType.BINARY, compress)
File "/usr/local/lib/python3.11/site-packages/aiohttp/http_websocket.py", line 601, in _send_frame
raise ConnectionResetError("Cannot write to closing transport")
ConnectionResetError: Cannot write to closing transport
ERROR:asyncio:Task exception was never retrieved
future: <Task finished name='Task-3054983' coro=<ClientWebSocketResponse.send_bytes() done, defined at /usr/local/lib/python3.11/site-packages/aiohttp/client_ws.py:153> exception=ConnectionResetError('Cannot write to closing transport')>
Traceback (most recent call last):
File "/usr/local/lib/python3.11/site-packages/aiohttp/client_ws.py", line 156, in send_bytes
await self._writer.send(data, binary=True, compress=compress)
File "/usr/local/lib/python3.11/site-packages/aiohttp/http_websocket.py", line 688, in send
await self._send_frame(message, WSMsgType.BINARY, compress)
File "/usr/local/lib/python3.11/site-packages/aiohttp/http_websocket.py", line 601, in _send_frame
raise ConnectionResetError("Cannot write to closing transport")
ConnectionResetError: Cannot write to closing transport
ERROR:asyncio:Task exception was never retrieved
future: <Task finished name='Task-3054985' coro=<ClientWebSocketResponse.send_bytes() done, defined at /usr/local/lib/python3.11/site-packages/aiohttp/client_ws.py:153> exception=ConnectionResetError('Cannot write to closing transport')>
Traceback (most recent call last):
File "/usr/local/lib/python3.11/site-packages/aiohttp/client_ws.py", line 156, in send_bytes
await self._writer.send(data, binary=True, compress=compress)
File "/usr/local/lib/python3.11/site-packages/aiohttp/http_websocket.py", line 688, in send
await self._send_frame(message, WSMsgType.BINARY, compress)
File "/usr/local/lib/python3.11/site-packages/aiohttp/http_websocket.py", line 601, in _send_frame
raise ConnectionResetError("Cannot write to closing transport")
ConnectionResetError: Cannot write to closing transport
ERROR:asyncio:Task exception was never retrieved
future: <Task finished name='Task-3054987' coro=<ClientWebSocketResponse.send_bytes() done, defined at /usr/local/lib/python3.11/site-packages/aiohttp/client_ws.py:153> exception=ConnectionResetError('Cannot write to closing transport')>
Traceback (most recent call last):
File "/usr/local/lib/python3.11/site-packages/aiohttp/client_ws.py", line 156, in send_bytes
await self._writer.send(data, binary=True, compress=compress)
File "/usr/local/lib/python3.11/site-packages/aiohttp/http_websocket.py", line 688, in send
await self._send_frame(message, WSMsgType.BINARY, compress)
File "/usr/local/lib/python3.11/site-packages/aiohttp/http_websocket.py", line 601, in _send_frame
raise ConnectionResetError("Cannot write to closing transport")
ConnectionResetError: Cannot write to closing transport
ERROR:asyncio:Task exception was never retrieved
future: <Task finished name='Task-3054989' coro=<ClientWebSocketResponse.send_bytes() done, defined at /usr/local/lib/python3.11/site-packages/aiohttp/client_ws.py:153> exception=ConnectionResetError('Cannot write to closing transport')>
Traceback (most recent call last):
File "/usr/local/lib/python3.11/site-packages/aiohttp/client_ws.py", line 156, in send_bytes
await self._writer.send(data, binary=True, compress=compress)
File "/usr/local/lib/python3.11/site-packages/aiohttp/http_websocket.py", line 688, in send
await self._send_frame(message, WSMsgType.BINARY, compress)
File "/usr/local/lib/python3.11/site-packages/aiohttp/http_websocket.py", line 601, in _send_frame
raise ConnectionResetError("Cannot write to closing transport")
ConnectionResetError: Cannot write to closing transport
ERROR:asyncio:Task exception was never retrieved
future: <Task finished name='Task-3054991' coro=<ClientWebSocketResponse.send_bytes() done, defined at /usr/local/lib/python3.11/site-packages/aiohttp/client_ws.py:153> exception=ConnectionResetError('Cannot write to closing transport')>
Traceback (most recent call last):
File "/usr/local/lib/python3.11/site-packages/aiohttp/client_ws.py", line 156, in send_bytes
await self._writer.send(data, binary=True, compress=compress)
File "/usr/local/lib/python3.11/site-packages/aiohttp/http_websocket.py", line 688, in send
await self._send_frame(message, WSMsgType.BINARY, compress)
File "/usr/local/lib/python3.11/site-packages/aiohttp/http_websocket.py", line 601, in _send_frame
raise ConnectionResetError("Cannot write to closing transport")
ConnectionResetError: Cannot write to closing transport
ERROR:asyncio:Task exception was never retrieved
future: <Task finished name='Task-3054993' coro=<ClientWebSocketResponse.send_bytes() done, defined at /usr/local/lib/python3.11/site-packages/aiohttp/client_ws.py:153> exception=ConnectionResetError('Cannot write to closing transport')>
Traceback (most recent call last):
File "/usr/local/lib/python3.11/site-packages/aiohttp/client_ws.py", line 156, in send_bytes
await self._writer.send(data, binary=True, compress=compress)
File "/usr/local/lib/python3.11/site-packages/aiohttp/http_websocket.py", line 688, in send
await self._send_frame(message, WSMsgType.BINARY, compress)
File "/usr/local/lib/python3.11/site-packages/aiohttp/http_websocket.py", line 601, in _send_frame
raise ConnectionResetError("Cannot write to closing transport")
ConnectionResetError: Cannot write to closing transport
ERROR:asyncio:Task exception was never retrieved
future: <Task finished name='Task-3054995' coro=<ClientWebSocketResponse.send_bytes() done, defined at /usr/local/lib/python3.11/site-packages/aiohttp/client_ws.py:153> exception=ConnectionResetError('Cannot write to closing transport')>
Traceback (most recent call last):
File "/usr/local/lib/python3.11/site-packages/aiohttp/client_ws.py", line 156, in send_bytes
await self._writer.send(data, binary=True, compress=compress)
File "/usr/local/lib/python3.11/site-packages/aiohttp/http_websocket.py", line 688, in send
await self._send_frame(message, WSMsgType.BINARY, compress)
File "/usr/local/lib/python3.11/site-packages/aiohttp/http_websocket.py", line 601, in _send_frame
raise ConnectionResetError("Cannot write to closing transport")
ConnectionResetError: Cannot write to closing transport
ERROR:asyncio:Task exception was never retrieved
future: <Task finished name='Task-3054997' coro=<ClientWebSocketResponse.send_bytes() done, defined at /usr/local/lib/python3.11/site-packages/aiohttp/client_ws.py:153> exception=ConnectionResetError('Cannot write to closing transport')>
Traceback (most recent call last):
File "/usr/local/lib/python3.11/site-packages/aiohttp/client_ws.py", line 156, in send_bytes
await self._writer.send(data, binary=True, compress=compress)
File "/usr/local/lib/python3.11/site-packages/aiohttp/http_websocket.py", line 688, in send
await self._send_frame(message, WSMsgType.BINARY, compress)
File "/usr/local/lib/python3.11/site-packages/aiohttp/http_websocket.py", line 601, in _send_frame
raise ConnectionResetError("Cannot write to closing transport")
ConnectionResetError: Cannot write to closing transport
在我的docker-compose中我有以下内容:
environment:
- PULSE_SERVER=unix:/tmp/pulseaudio.socket
- PULSE_COOKIE=/tmp/pulseaudio.cookie
devices:
- /dev/snd:/dev/snd
group_add:
- audio
我究竟做错了什么?