14 lines
349 B
Python
14 lines
349 B
Python
from flask_sqlalchemy import SQLAlchemy
|
|
from flask_mail import Mail
|
|
from flask_limiter import Limiter
|
|
from flask_limiter.util import get_remote_address
|
|
|
|
db = SQLAlchemy()
|
|
mail = Mail()
|
|
limiter = Limiter(
|
|
get_remote_address,
|
|
storage_uri="redis://cache:6379",
|
|
storage_options={"socket_connect_timeout": 30},
|
|
strategy="fixed-window",
|
|
)
|