Reputation: 6403
I'm learning Elixir/Phoenix Framework and want to learn how to deploy to a host where I'm not allowed to create additional DB's. Most tutorials instruct that I run mix ecto.create
to initialize it, but it seems to want to create new DB's. To simulate the host settings, I've tried to create a DB of my own with a pre-made user and then I ran mix ecto.migrate
to initialize it. It looks fine:
$ mix ecto.migrate
Compiling 12 files (.ex)
Generated phoenix0 app
And after that mix phoenix.server
starts and all seems well. My question: is this enough to run a Phoenix app or should I do something more?
Upvotes: 0
Views: 181
Reputation: 222388
ecto.create
is just a convenience to quickly create the database(s) when creating a new app or using an app for the first time on a system. You don't need to run it and you can safely ignore that step in the tutorials if the database already exists. If ecto.migrate
ran the migrations and you didn't get any errors, you're good.
Upvotes: 2