Merge branch 'feature/core' of v2.discours.io:core into feature/core

This commit is contained in:
Untone 2024-01-28 10:03:51 +03:00
commit a98284522b
3 changed files with 11 additions and 11 deletions

View File

@ -1,8 +1,5 @@
name: 'Deploy to core'
on:
push:
branches:
- main
on: [push]
jobs:
deploy:
@ -24,8 +21,7 @@ jobs:
- name: Push to dokku
uses: dokku/github-action@master
with:
branch: 'main'
branch: 'feature/core'
git_remote_url: 'ssh://dokku@v2.discours.io:22/core'
ssh_private_key: ${{ secrets.SSH_PRIVATE_KEY }}
git_push_flags: '--force'

View File

@ -1,4 +1,5 @@
import os
import sentry_sdk
from importlib import import_module
from os.path import exists
@ -26,7 +27,11 @@ schema = make_executable_schema(load_schema_from_path('schemas/core.graphql'), r
async def start_up():
print(f'[main] starting in {MODE} mode')
await redis.connect()
with sentry_sdk.start_transaction(
op="task",
name="Redis Connection"
):
await redis.connect()
# start viewed service
await ViewedStorage.init()
@ -40,7 +45,6 @@ async def start_up():
if MODE == 'production':
# sentry monitoring
try:
import sentry_sdk
sentry_sdk.init(
SENTRY_DSN,

View File

@ -11,7 +11,7 @@ python = "^3.12"
SQLAlchemy = "^2.0.22"
psycopg2-binary = "^2.9.9"
redis = {extras = ["hiredis"], version = "^5.0.1"}
sentry-sdk = "^1.39.1"
sentry-sdk = "^1.4.1"
starlette = "^0.36.1"
gql = "^3.4.1"
ariadne = "^0.21"