Phoenix (or Ecto) defaults PostgreSQL as their database of choice. What if you just want to do something simple or just start learning Phoenix and too lazy to set up a Postgres server (like me)?
After setting up your Erlang and Elixir in your machine, you need to install
hex. If you haven't had it installed, run this:
Then you need to install Phoenix application generator:
mix archive.install hex phx_new
To kick start your Phoenix project, run this line:
mix phx.new sqlite_app --database sqlite3
Now you're ready to develop your next awesome Phoenix project with SQLite.
--database flag tells the generator that we want to use SQLite in our project and added
ecto_sqlite3 as a dependency so we can use it with
Actually, Phoenix is well documented (and from what I heard, Elixir projects are generally well documented). You can find most of what you want to do when kickstarting your Phoenix project in this hexdocs page.
to create your SQLite database file in your project direcory.
I hope this helps and hope you have some fun times ahead!