Skip to content
This repository was archived by the owner on Aug 1, 2024. It is now read-only.

Commit 65623f5

Browse files
authored
Merge pull request #1123 from openedx/farhanumar/psre-2485-dbcopy80
chore: Added dbcopy80 command to Makefile
2 parents 2b61679 + f628edd commit 65623f5

1 file changed

Lines changed: 5 additions & 0 deletions

File tree

Makefile

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -461,6 +461,11 @@ dev.shell.%: ## Run a shell on the specified service's container.
461461
dev.dbshell:
462462
docker-compose exec mysql57 bash -c "mysql"
463463

464+
dev.dbcopy8.%: ## Copy data from old mysql 5.7 container into a new 8 db
465+
docker-compose exec mysql57 bash -c "mysqldump $*" > .dev/$*.sql
466+
docker-compose exec -T mysql80 bash -c "mysql $*" < .dev/$*.sql
467+
rm .dev/$*.sql
468+
464469
dev.dbshell.%: ## Run a SQL shell on the given database.
465470
docker-compose exec mysql57 bash -c "mysql $*"
466471

0 commit comments

Comments
 (0)