chore: initial import of CoHaiSe Cloud
PR — Ouverture automatique / create-pr (push) Failing after 1s
PR — Ouverture automatique / create-pr (push) Failing after 1s
Standalone files & media application: React/Vite frontend with the @cohaise/ui design system, Hono + MariaDB backend, nginx reverse proxy, Docker Compose stack, migrations 000-006, and project docs. Adds Gitea Actions workflows for deployment, automatic pull requests, and Renovate dependency updates.
This commit is contained in:
@@ -0,0 +1,24 @@
|
||||
-- 006_public_folder.sql
|
||||
--
|
||||
-- Le modele prevoyait depuis 004 un dossier systeme public (folders.is_system,
|
||||
-- access_type='public'), mais aucune ligne n'existait : les comptes n'avaient
|
||||
-- donc aucun espace commun. Cette migration cree ce dossier une seule fois.
|
||||
--
|
||||
-- Elle retire aussi deux reglages sans effet depuis la suppression de
|
||||
-- share_links par 004 (donnees mortes).
|
||||
|
||||
-- Un unique dossier systeme, a la racine, rattache au premier emplacement actif.
|
||||
-- Idempotent : ne fait rien si un dossier systeme existe deja.
|
||||
INSERT INTO folders
|
||||
(id, storage_location_id, parent_id, name, description, owner_id, created_by, access_type, is_system)
|
||||
SELECT UUID(), sl.id, NULL, 'Public',
|
||||
'Espace commun : chaque compte peut y deposer des fichiers.',
|
||||
NULL, NULL, 'public', 1
|
||||
FROM storage_locations sl
|
||||
WHERE sl.is_active = 1
|
||||
AND sl.deleted_at IS NULL
|
||||
AND NOT EXISTS (SELECT 1 FROM folders f WHERE f.is_system = 1)
|
||||
ORDER BY sl.id
|
||||
LIMIT 1;
|
||||
|
||||
DELETE FROM settings WHERE setting_key IN ('allow_public_shares', 'default_share_expiry_days');
|
||||
Reference in New Issue
Block a user