fix(publish): use relative symlink for latest, set 0644 perms, populate rowCounts from dump

This commit is contained in:
Lars committed 2026-10-29 16:02:37 +01:00
1 parent 0bbc4ce440
commit 7116215477
3 files changed
+39 -10

No files matched your search

+10
View File
@@ -316,6 +316,16 @@ def main():
write_result(args.result, {'status': 'error', 'exit_code': EXIT_EXEC_ERROR, 'detail': msg})
return EXIT_EXEC_ERROR
# Verify active media_assets count in staging database
act_res = psql_exec(tcfg, staging_db, "SELECT COUNT(*)::int FROM media_assets WHERE lifecycle_state = 'active';")
if act_res.returncode == 0 and act_res.stdout.strip().isdigit():
act_cnt = int(act_res.stdout.strip())
if act_cnt < 1:
drop_db_if_exists(tcfg, staging_db)
msg = f'Plausibility check failed: expected active media_assets, found {act_cnt}'
write_result(args.result, {'status': 'error', 'exit_code': EXIT_EXEC_ERROR, 'detail': msg})
return EXIT_EXEC_ERROR
if args.sessions == 'clear':
print('5. Clearing active user sessions in staging DB (--sessions clear)...')
psql_exec(tcfg, staging_db, 'TRUNCATE TABLE sessions;')