antedebaas / Viesti-Reports

DMARC & SMTP-TLS Reports processor and visualizer and BIMI file hoster
https://docs.viestireports.com/
GNU General Public License v2.0
79 stars 16 forks source link

No database structure on install #136

Closed rvd0167 closed 2 months ago

rvd0167 commented 2 months ago

No database structure is created on a fresh install. Setup sees I should install updates but they crash.

I did a fresh git install in Debian/Apache/PHP8.3/MariaDB. Followed by bash /update.sh chown -R : /Viesti-Reports Filled the form shown by setup. Setup shows: there are new schema updates availibe <= Typo in setup The following migrations have not been processed DoctrineMigrations\Version20230930193129 DoctrineMigrations\Version20240617165805 DoctrineMigrations\Version20240317202800 DoctrineMigrations\Version20230928180433 DoctrineMigrations\Version20230809184012 DoctrineMigrations\Version20240304200130 DoctrineMigrations\Version20240619204435 DoctrineMigrations\Version20240302153203 DoctrineMigrations\Version20240214121100 DoctrineMigrations\Version20240124150025 DoctrineMigrations\Version20240124174018 DoctrineMigrations\Version20231014141450 DoctrineMigrations\Version20230919194011

But they all crash as there is no database structure yet. The only table created with the update button is 'doctrine_migration_versions'

Checked it with PHPMyAdmin => No tables in database before update button. And 'doctrine_migration_versions' after update button. Checked database login/password/host and verified this on the command line and entries in with .env.local

[DATESTRING] [proxy_fcgi:error] [pid 982027:tid 140600688965312] [remote IPSTRING:63857] AH01071: Got error 'PHP message: [critical] Error thrown while running command "doctrine:migrations:migrate --no-interaction". Message: "An exception occurred while executing a query: SQLSTATE[42000]: Syntax error or access violation: 1064 You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near 'NOT NULL, report_id INTEGER NOT NULL, source_ip VARCHAR(255) NOT NULL, count ...' at line 1"', referer: ME_STRING

Please assist.

Ronald

rvd0167 commented 2 months ago

I looked at https://github.com/antedebaas/Viesti-Reports/issues/104 I did the update.sh in console again while the update button was still showing in web setup. After that press update button. And it worked. Could create an admin account and login to the dashboard.

antedebaas commented 2 months ago

Note to self: fix typo and investigate possible initial setup issue