Fix: generated sql has varying timestamps breaking the cache hash

This commit is contained in:
Greyscale 2022-09-01 16:36:30 +02:00
parent f15b3bf189
commit 7c0b1f8c3c
No known key found for this signature in database
GPG key ID: 74BAFF55434DA4B2
3 changed files with 8 additions and 9 deletions

View file

@ -1,6 +1,5 @@
All:
* S3 pruner
PostgreSQL:
*
MariaDB:
* generated sql has varying timestamps breaking the cache hash

View file

@ -42,8 +42,8 @@ services:
- "127.0.0.127:5432:5432"
depends_on:
- minio
# volumes:
# - ./:/sync
volumes:
- ./:/sync
mariadb-10.9:
image: benzine/mysql:10.9
@ -68,8 +68,8 @@ services:
- "127.0.0.127:3306:3306"
depends_on:
- minio
# volumes:
# - ./:/sync
volumes:
- ./:/sync
mariadb-10.3:
image: benzine/mysql:10.3
@ -85,5 +85,5 @@ services:
- "127.0.0.127:3306:3306"
depends_on:
- minio
# volumes:
# - ./:/sync
volumes:
- ./:/sync

View file

@ -10,7 +10,7 @@ class MysqlSyncer extends AbstractSyncer
{
// Dump file from Postgres
$dumpFile = 'dump.sql';
$command = sprintf('mysqldump -u $MARIADB_USER -p$MARIADB_PASSWORD --extended-insert --quick --add-locks --add-drop-database --add-drop-table --add-drop-trigger $MARIADB_DATABASE > /dumps/%s', $dumpFile);
$command = sprintf('mysqldump -u $MARIADB_USER -p$MARIADB_PASSWORD --extended-insert --quick --add-locks --add-drop-database --add-drop-table --add-drop-trigger --skip-dump-date $MARIADB_DATABASE > /dumps/%s', $dumpFile);
passthru($command);
// Verify the dump worked