forked from mtusi2026/mtusi2026lab7
База lab7: контракт 1.7.0 и реализация lab1–lab6
Перенесены cmd/internal/config, compose.yaml, Dockerfile, скрипты, student-tests и evidence из mtusi-messenger (master, lab6). Skeleton lab7 (openapi/infrastructure 1.7.0, trust-matrix.md, security/THREAT_MODEL.md, infra/openbao, tests/security.py) сохранён; make test-security добавлен в Makefile.
This commit is contained in:
@@ -0,0 +1,54 @@
|
||||
env: dev
|
||||
|
||||
server:
|
||||
host: 0.0.0.0
|
||||
port: 8080
|
||||
read_header_timeout: 10s
|
||||
shutdown_timeout: 10s
|
||||
# Предел размера тела запроса; JSON API ЛР3 укладывается в сотни килобайт,
|
||||
# а загрузка вложений ЛР4 (до 10 MiB) поднимает это значение явно.
|
||||
max_body_bytes: 262144
|
||||
|
||||
log:
|
||||
level: info
|
||||
format: json
|
||||
|
||||
postgres:
|
||||
host: localhost
|
||||
port: 5432
|
||||
database: messenger
|
||||
user: messenger
|
||||
# Dev default for a local run without environment overrides; POSTGRES_PASSWORD wins.
|
||||
password: messenger
|
||||
ssl_mode: disable
|
||||
max_conns: 10
|
||||
min_conns: 1
|
||||
max_conn_lifetime: 1h
|
||||
max_conn_idle_time: 30m
|
||||
connect_timeout: 5s
|
||||
query_timeout: 5s
|
||||
|
||||
redis:
|
||||
enabled: true
|
||||
host: localhost
|
||||
port: 6379
|
||||
db: 0
|
||||
# -1 disables go-redis retries; 0 keeps the library default (3 retries).
|
||||
max_retries: -1
|
||||
dial_timeout: 300ms
|
||||
read_timeout: 200ms
|
||||
write_timeout: 200ms
|
||||
pool_size: 10
|
||||
|
||||
cache:
|
||||
enabled: true
|
||||
chat_list_ttl: 5m
|
||||
lock_ttl: 10s
|
||||
lock_wait_timeout: 2s
|
||||
|
||||
session:
|
||||
ttl_seconds: 3600
|
||||
|
||||
# Retention of a message Idempotency-Key; contract 1.3.0 requires ≥ 24 h.
|
||||
idempotency:
|
||||
ttl_seconds: 86400
|
||||
Reference in New Issue
Block a user