add push notification support
This commit is contained in:
parent
6a69c5a34d
commit
1b1dcc3755
12 changed files with 175 additions and 10 deletions
34
alembic/versions/f73144466860_alert_encryption_table.py
Normal file
34
alembic/versions/f73144466860_alert_encryption_table.py
Normal file
|
|
@ -0,0 +1,34 @@
|
|||
"""alert encryption table
|
||||
|
||||
Revision ID: f73144466860
|
||||
Revises: e6b8e42fa629
|
||||
Create Date: 2024-07-16 06:55:24.078521
|
||||
|
||||
"""
|
||||
from typing import Sequence, Union
|
||||
|
||||
from alembic import op
|
||||
import sqlalchemy as sa
|
||||
|
||||
|
||||
# revision identifiers, used by Alembic.
|
||||
revision: str = 'f73144466860'
|
||||
down_revision: Union[str, None] = 'e6b8e42fa629'
|
||||
branch_labels: Union[str, Sequence[str], None] = None
|
||||
depends_on: Union[str, Sequence[str], None] = None
|
||||
|
||||
|
||||
def upgrade() -> None:
|
||||
op.create_table(
|
||||
"alert_endpoints",
|
||||
sa.Column("id", sa.INT, autoincrement=True, primary_key=True),
|
||||
sa.Column("username", sa.VARCHAR(64), index=True),
|
||||
sa.Column("url", sa.VARCHAR(2048), unique=True),
|
||||
sa.Column("auth", sa.VARCHAR(2048)),
|
||||
sa.Column("p256dh", sa.VARCHAR(2048)),
|
||||
sa.Column("created_at", sa.TIMESTAMP(), server_default=sa.func.now()),
|
||||
)
|
||||
|
||||
|
||||
def downgrade() -> None:
|
||||
op.drop_table("alert_endpoints")
|
||||
Loading…
Add table
Add a link
Reference in a new issue