I’m curently upgrading an old trellis project which uses trellis-database-uploads-migration to push / pull and backup databases.
It looks pretty old so I’ve no idea if anyone still uses it. However, a recent compatibility change in mariadb introduces a breaking change that may affect anyone using a similar approach to
wp db export --allow-root - | gzip > {{ dump_file }}
This change inserts a comment at the top of the file which causes wp db import - to fail on \-
/*!999999\- enable the sandbox mode */
piping the export into awk as before gzipping seems to work conditionally but isn’t fully tested as yet:
awk 'NR == 1 && /!999999\\- enable the sandbox mode / {next} {print}'
refs: