|
||
---|---|---|
assets | ||
config | ||
lib | ||
priv | ||
test | ||
.buildpacks | ||
.formatter.exs | ||
.gitignore | ||
.tool-versions | ||
Dockerfile | ||
README.md | ||
deployment.yaml | ||
elixir_buildpack.config | ||
mix.exs | ||
mix.lock | ||
phoenix_static_buildpack.config |
README.md
Entendu
To start your Phoenix server:
- (optional) Install 'ASDF' along with the 'Erlang', 'Elixir', and 'Node' plugins
- (optional) Run
asdf install
. Now this project will always use the correct erlang/elixir/node/npm versions. - Install dependencies with
mix deps.get
- Create and migrate your database with
mix ecto.setup
- Install Node.js dependencies with
npm install
inside theassets
directory - Run
mix phx.gen.cert
to use HTTPS during development, required for OAuth - Start Phoenix endpoint with
mix phx.server
Now you can visit localhost:4000
from your browser.
Ready to run in production? Please check our deployment guides.
Setting up OAuth
Add the OAuth providers you'll be using to the providers array.
use Mix.Config
config :ueberauth, Ueberauth,
providers: [
github: {Ueberauth.Strategy.Github, []}
]
You'll need to visit each provider's site and set up OAuth. This usually entails creating an OAuth App to generate a client_id, and generating a client_secret. Then create a dev.secret.exs
file in your config folder and add your client_id & secret to your provider's ueberauth config.
config :ueberauth, Ueberauth.Strategy.Github.OAuth,
client_id: "some_client_id",
client_secret: "some_secret_key"