mirror of
https://github.com/dani-garcia/vaultwarden.git
synced 2025-12-10 17:23:04 +03:00
wrong migrate sqlite to mysql doc #1453
Reference in New Issue
Block a user
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @scofieldpeng on GitHub.
Subject of the issue
wrong doc in migrate from sqlite to mysql
Deployment environment
Install method: docker
Clients used:
Reverse proxy and version:
MySQL/MariaDB or PostgreSQL version:
Other relevant details:
Steps to reproduce
docker pull bitwarden_rs/server:1.19.0(by the way, the `bitwarden_rs/server:1.19.0-alpine don't support mysql)docker run command to let bitwarden create the latest tables to mysqlsqlite3 db.sqlite3 .dump | grep "^INSERT INTO" | grep -v "__diesel_schema_migrations" > sqlitedump.sql ; echo -ne "SET FOREIGN_KEY_CHECKS=0;\n$(cat sqlitedump.sql)" > mysqldump.sqlin bitwarden data dir.error (1064): Syntax error near '"users" VALUES('9b5c2d13-8c4f-47e9-bd94-f0d7036ff581'*********)sed -i 's#\"#\#g' mysqldump.sql, in fact, this command will not run correctly, I search the right command in issue, and run the correct commandsed -i s#\"#\#g mysqldump.sqlthe problem is the sed command, it want to change
to
but it also remove the all
"in fielddatain tablecipher, so the json string broken.help this issue can help those people want to migrate from sqlite to mysql :-)
Expected behaviour
Actual behaviour
Troubleshooting data