mirror of
https://github.com/HyPnoTiiK/stream-fusion.git
synced 2026-07-28 15:02:46 +00:00
12 lines
366 B
Python
12 lines
366 B
Python
from sqlalchemy.ext.asyncio import create_async_engine
|
|
|
|
from .base import Base
|
|
from .models.apikey_model import APIKeyModel
|
|
from stream_fusion.settings import settings
|
|
|
|
|
|
async def init_db():
|
|
engine = create_async_engine(str(settings.pg_url))
|
|
async with engine.begin() as conn:
|
|
await conn.run_sync(Base.metadata.create_all)
|
|
await engine.dispose()
|