mirror of
https://github.com/suyiiyii/nonebot-bison.git
synced 2025-06-02 09:26:12 +08:00
fix chromium
This commit is contained in:
parent
2178f9667f
commit
8d02c8f22a
@ -1,6 +1,6 @@
|
||||
FROM python:3.9
|
||||
RUN echo "deb http://mirrors.aliyun.com/debian/ buster main contrib non-free\ndeb http://mirrors.aliyun.com/debian/ buster-updates main contrib non-free" > /etc/apt/sources.list && \
|
||||
apt-get update && apt-get install -y fonts-wqy-microhei
|
||||
apt-get update && apt-get install -y fonts-wqy-microhei chromium
|
||||
RUN python3 -m pip config set global.index-url https://mirrors.aliyun.com/pypi/simple
|
||||
RUN python3 -m pip install poetry && poetry config virtualenvs.create false
|
||||
WORKDIR /app
|
||||
|
@ -21,9 +21,9 @@ class Render(metaclass=Singleton):
|
||||
|
||||
async def init(self):
|
||||
if plugin_config.hk_reporter_use_local:
|
||||
browser = await launch(executablePath='/usr/bin/chromium')
|
||||
browser = await launch(executablePath='/usr/bin/chromium', args=['--no-sandbox'])
|
||||
else:
|
||||
browser = await launch()
|
||||
browser = await launch(args=['--no-sandbox'])
|
||||
self.page = await browser.newPage()
|
||||
|
||||
async def text_to_pic(self, text: str) -> str:
|
||||
|
Loading…
x
Reference in New Issue
Block a user