Phoenix Fullstack application

The "Discuss" application simulates a forum where comments can be added in real time for a given topic and related to a user.

It uses dependencies that allow login with GitHub (Ueberauth) and uses plugs to make the application safer and less susceptible to external attacks. Where the user can only perform certain actions if they are logged in or if they really own the topic, etc.

Github Ueberauth Example Repository: https://github.com/ueberauth/ueberauth_example

Useful mix commands for Phoenix framework

To start your Phoenix server:

  • Install dependencies with mix deps.get
  • Create an .env file from the .env.example and fill it in
  • You can create an SECRET_KEY_BASE using the mix phx.gen.secret command
  • To create new OAuth Github App (required to populate .env GITHUB_CLIENT_ID and GITHUB_CLIENT_SECRET fields): https://github.com/settings/developers
  • Create, migrate your database and run seeds.exs with mix ecto.setup. Unfortunately, the environment variables of the created .env file are not loaded when executing this command. Then you will have to manually replace the database access data in the dev.exs file
  • Start Phoenix endpoint with mix phx.server or inside IEx with iex -S mix phx.server

Now you can visit localhost:4000 from your browser.