From 518b89acf583c78a5725af01a78e325bbbd38e9f Mon Sep 17 00:00:00 2001 From: felinae98 <731499577@qq.com> Date: Wed, 8 Dec 2021 14:36:32 +0800 Subject: [PATCH] build sentry --- .circleci/config.yml | 15 +++++++++++++++ docker/Dockerfile_with_frontend_sentry | 3 ++- 2 files changed, 17 insertions(+), 1 deletion(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index 9cedd03..f5c5809 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -77,6 +77,21 @@ workflows: tags: ignore: /.*/ tag: ${CIRCLE_BRANCH} + - docker/publish: + <<: *docker-push + dockerfile: docker/Dockerfile_with_frontend_sentry + name: "docker/publish-sentry" + tag: sentry, ${CIRCLE_TAG}-sentry + - docker/publish: + <<: *docker-push + name: "docker/publish-debug-sentry" + dockerfile: docker/Dockerfile_with_frontend_sentry + filters: + branches: + only: [main, dev] + tags: + ignore: /.*/ + tag: ${CIRCLE_BRANCH}-sentry jobs: build-frontend: diff --git a/docker/Dockerfile_with_frontend_sentry b/docker/Dockerfile_with_frontend_sentry index 60d1aff..4cb7efc 100644 --- a/docker/Dockerfile_with_frontend_sentry +++ b/docker/Dockerfile_with_frontend_sentry @@ -2,7 +2,8 @@ FROM python:3.9 RUN python3 -m pip install poetry && poetry config virtualenvs.create false WORKDIR /app COPY ./pyproject.toml ./poetry.lock* /app/ -RUN poetry add +RUN poetry add nonebot-plugin-sentry && \ + sed '/nonebot.load_builtin_plugins()/a nonebot.load_plugin("nonebot_plugin_sentry")' -i bot.py RUN poetry install --no-root --no-dev ADD src /app/src ADD bot.py /app/