--- первый запуск (из логов сервиса migrate) --- migrate-1 | apply 0001_init migrate-1 | migrations complete: 1 file(s) --- повторный запуск --- Container mtusi-lab2-postgres-1 Running Container mtusi-lab2-postgres-1 Waiting Container mtusi-lab2-postgres-1 Healthy Container mtusi-lab2-migrate-run-003b830c021a Creating Container mtusi-lab2-migrate-run-003b830c021a Created skip 0001_init migrations complete: 1 file(s) --- схема --- Table "public.messages" Column | Type | Collation | Nullable | Default | Storage | Compression | Stats target | Description ------------+--------------------------+-----------+----------+---------+----------+-------------+--------------+------------- id | uuid | | not null | | plain | | | chat_id | uuid | | not null | | plain | | | sender_id | uuid | | not null | | plain | | | text | bytea | | not null | | extended | | | created_at | timestamp with time zone | | not null | | plain | | | Indexes: "messages_pkey" PRIMARY KEY, btree (id) "messages_history_idx" btree (chat_id, created_at, id) Check constraints: "messages_text_size" CHECK (octet_length(text) >= 1 AND octet_length(text) <= 16000) Foreign-key constraints: "messages_chat_id_fkey" FOREIGN KEY (chat_id) REFERENCES chats(id) ON DELETE CASCADE "messages_sender_id_fkey" FOREIGN KEY (sender_id) REFERENCES users(id) ON DELETE RESTRICT Access method: heap version | checksum | applied_at -----------+------------------------------------------------------------------+------------------------------- 0001_init | 4fd0a8c68a5cffd3ae67a21646eb1928477d18b8716e68c1220469d858ccb9c1 | 2026-10-23 20:10:21.263237+00 (1 row)