Merge pull request #296 from omartell/bug/migrations-#291

[Fix #291] Fix command to run migrations
This commit is contained in:
P 2018-02-20 12:14:41 +01:00 committed by GitHub
commit 2a88a6ded7
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 3 additions and 4 deletions

View File

@ -54,10 +54,9 @@ repl-server
(cond
(some #{"migrate" "rollback"} args)
(do
(mount/start
#'commiteth.config/env
#'commiteth.db.core/*db*)
(migrations/migrate args (select-keys env [:jdbc-database-url]))
(mount/start #'commiteth.config/env)
(migrations/migrate args {:database-url (:jdbc-database-url env)})
(log/info "Successfully ran" (first args))
(System/exit 0))
:else
(start-app args)))