Page MenuHomePhabricator

[keyserver] Factor out create-db.js script into setupDB function
ClosedPublic

Authored by ashoat on May 26 2022, 1:01 PM.
Tags
None
Referenced Files
Unknown Object (File)
Wed, Nov 27, 7:45 PM
Unknown Object (File)
Oct 28 2024, 3:03 AM
Unknown Object (File)
Oct 28 2024, 3:03 AM
Unknown Object (File)
Oct 28 2024, 3:02 AM
Unknown Object (File)
Oct 28 2024, 2:50 AM
Unknown Object (File)
Oct 25 2024, 7:49 PM
Unknown Object (File)
Oct 24 2024, 1:41 AM
Unknown Object (File)
Oct 24 2024, 1:40 AM

Details

Summary

Today, the only way to setup the MySQL database is via the create-db.js script. In a following diff, I'm working on making Node automatically setup the database if it is not set up.

Depends on D4141

Test Plan
  1. mysql -uroot -p and then run CREATE DATABASE comm3; GRANT ALL ON comm3.* TO comm@localhost;
  2. Update keyserver/secrets/db_config.json to use the new comm3 database
  3. Run yarn dev or yarn prod-build in the keyserver directory
  4. mysql -uroot -p and then run USE comm3; SHOW TABLES; and see if the tables were all created

Diff Detail

Repository
rCOMM Comm
Lint
Lint Not Applicable
Unit
Tests Not Applicable