1
0
mirror of git://f0xx.org/ac/ac-deploy synced 2026-07-29 07:37:47 +03:00

Enable lab media_pipelines in composed config and wire ac-ms-media-transcode.

Overlay media pipeline PHP/JS/SQL on compose, nginx HLS location, enable
feature in lab config.php, and ensure media storage dirs on BE nodes.

Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
Anton Afanasyeu
2026-07-11 15:27:01 +02:00
parent 54174e7497
commit b8bd0e673c
9 changed files with 898 additions and 0 deletions

View File

@@ -0,0 +1,29 @@
-- Media pipelines (V.2x experimental restream) — MariaDB
-- mysql -u root -p androidcast_crashes < sql/migrations/081_media_pipelines.sql
CREATE TABLE IF NOT EXISTS media_pipelines (
id INT UNSIGNED AUTO_INCREMENT PRIMARY KEY,
company_id INT UNSIGNED NOT NULL DEFAULT 1,
owner_user_id INT UNSIGNED NOT NULL,
name VARCHAR(128) NOT NULL,
source_url TEXT NOT NULL,
source_fmt VARCHAR(64) NULL,
audio_source TEXT NULL,
filter_profile VARCHAR(32) NOT NULL DEFAULT 'default',
output_preset VARCHAR(16) NOT NULL DEFAULT '1080p',
run_mode ENUM('full','encode_only') NOT NULL DEFAULT 'full',
status ENUM('idle','starting','running','stopping','error') NOT NULL DEFAULT 'idle',
hls_slug VARCHAR(64) NULL,
pid_encode INT NULL,
pid_fanout INT NULL,
work_dir TEXT NULL,
record_path TEXT NULL,
hls_playlist_url TEXT NULL,
probe_json LONGTEXT NULL,
last_error TEXT NULL,
created_at TIMESTAMP NOT NULL DEFAULT CURRENT_TIMESTAMP,
updated_at TIMESTAMP NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP,
KEY idx_mp_company (company_id, status),
KEY idx_mp_owner (owner_user_id),
KEY idx_mp_status (status)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;

View File

@@ -0,0 +1,28 @@
-- Media pipelines — SQLite (local dev)
CREATE TABLE IF NOT EXISTS media_pipelines (
id INTEGER PRIMARY KEY AUTOINCREMENT,
company_id INTEGER NOT NULL DEFAULT 1,
owner_user_id INTEGER NOT NULL,
name TEXT NOT NULL,
source_url TEXT NOT NULL,
source_fmt TEXT NULL,
audio_source TEXT NULL,
filter_profile TEXT NOT NULL DEFAULT 'default',
output_preset TEXT NOT NULL DEFAULT '1080p',
run_mode TEXT NOT NULL DEFAULT 'full',
status TEXT NOT NULL DEFAULT 'idle',
hls_slug TEXT NULL,
pid_encode INTEGER NULL,
pid_fanout INTEGER NULL,
work_dir TEXT NULL,
record_path TEXT NULL,
hls_playlist_url TEXT NULL,
probe_json TEXT NULL,
last_error TEXT NULL,
created_at TEXT NOT NULL DEFAULT (datetime('now')),
updated_at TEXT NOT NULL DEFAULT (datetime('now'))
);
CREATE INDEX IF NOT EXISTS idx_mp_company ON media_pipelines (company_id, status);
CREATE INDEX IF NOT EXISTS idx_mp_owner ON media_pipelines (owner_user_id);