This commit is contained in:
2026-09-28 23:15:47 +05:30
commit 605c6a2e58
41 changed files with 4299 additions and 0 deletions
+16
View File
@@ -0,0 +1,16 @@
-- Run as an admin, before the app starts.
-- Do not create a remote root, and do not grant this user '@'%'.
-- The app user cannot DELETE and cannot apply DDL.
-- Soft-delete is an UPDATE of deleted_at.
-- Replace the password, then: chmod 600 this file if you fill in a real password.
CREATE DATABASE IF NOT EXISTS hundredkmph CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci;
CREATE USER IF NOT EXISTS 'hundredkmph'@'localhost' IDENTIFIED BY 'replace-with-a-long-random-password';
GRANT SELECT, INSERT, UPDATE ON hundredkmph.* TO 'hundredkmph'@'localhost';
FLUSH PRIVILEGES;
-- Then apply the migration as an admin (the app user cannot):
-- mariadb hundredkmph < /opt/hundredkmph/src/web/db/001_init.sql