The architecture is moving toward:
- Hetzner as the long-running backend host
- Hetzner MySQL as the main database host
- DreamHost no longer being the long-term database home
At the time of writing, Hetzner already has:
- MySQL installed
- MySQL active
- bound to
127.0.0.1:3306
That is a strong starting point.
bobsgamebackend services connect to local Hetzner MySQLfwberbackend services that move to Hetzner connect to the same MySQL host via localhost- a shared MySQL database can be used if desired, with app-level table prefixes
- application users can still remain separate per app/service even if the database is shared
Recommended conventions:
- shared database name:
platform_shared bobsgametable prefix:bg_fwbertable prefix:fw_
Prefer separate DB users for each app even if they share one database:
bg_app→ uses tables prefixed withbg_fw_app→ uses tables prefixed withfw_
The separation in MySQL is therefore mostly by:
- runtime config
- migration discipline
- table naming conventions
Example SQL template is included here:
server/ops/mysql/create-app-db.sql.example
Run locally:
BACKEND_HOST=5.161.250.43 BACKEND_USER=root ./scripts/check-mysql-hetzner.shUse the example SQL template and create the shared database plus the application users you want.
If there is no meaningful production user data yet, the simplest path is often:
- create the schema fresh on Hetzner
- run app migrations / bootstrap scripts
- skip legacy dump/import entirely
If you do need to import legacy content later, the general pattern is:
mysqldump -h OLD_MYSQL_HOST -u OLD_USER -p --databases OLD_DATABASE > old_database.sql
mysql -u root -p < old_database.sqlChange application DB hosts to the Hetzner-local database location. For services running on the same Hetzner box, use:
127.0.0.1- or local socket/localhost depending on the runtime
After migration, verify:
- app can connect
- reads work
- writes work
- schema-dependent features function
- create the shared MySQL database on Hetzner
- set the namespace/prefix rules (
bg_/fw_) - recreate
bobsgameschema state there first - verify app functionality
- recreate or migrate
fwber - cut over remaining app configs
REDIS_SHARED_SERVICES.mdPOSTGRES_SHARED_SERVICES.mdHETZNER_UNIFIED_STACK_STATUS.mdBACKEND_DEPLOY.mdHETZNER_SETUP.md