dipeshdulal / clean-gin

Implementation of clean architecture in Go, Gin with dependency injection.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Creating migration depends on docker

BinodKafle opened this issue · comments

When I tried to create migration without starting the server on docker, it throws the following error
image
I think creating migration should not depend on whether the server is started or not and more importantly it's started on docker or not.

Yes, I think we need to decouple the migration logic whether to use docker or base system for migration runner.
Commands like;

  • make docker migrate

Or using flags in make command.
I don't know much about the make command but @dipeshhkc can shed some light into this as well.

Looks like; this Stack Overflow answer has the solution to send custom variables to make file.

make foo=bar target

We could use this syntax to migrate without docker. eg; make provider=host migrate for host migration runner and make provider=docker migrate for docker based migration runner.