mirror of
https://github.com/Icinga/icingaweb2-module-director.git
synced 2025-08-15 14:58:11 +02:00
If you try to set up icinga director with the latest minor version of MySQL 8.4+, the schema creation will fail with confusing SQL error messages. This commit aims to fix that. https://dev.mysql.com/doc/refman/8.4/en/mysql-nutshell.html#mysql-nutshell-deprecations
18 lines
507 B
SQL
18 lines
507 B
SQL
ALTER TABLE director_activity_log
|
|
DROP INDEX checksum,
|
|
ADD UNIQUE INDEX checksum (checksum);
|
|
|
|
ALTER TABLE director_generated_config
|
|
DROP FOREIGN KEY director_generated_config_activity;
|
|
|
|
ALTER TABLE director_generated_config
|
|
ADD CONSTRAINT director_generated_config_activity
|
|
FOREIGN KEY (last_activity_checksum)
|
|
REFERENCES director_activity_log (checksum)
|
|
ON DELETE RESTRICT
|
|
ON UPDATE RESTRICT;
|
|
|
|
INSERT INTO director_schema_migration
|
|
(schema_version, migration_time)
|
|
VALUES (188, NOW());
|