Skip to content

Instantly share code, notes, and snippets.

@EssenceOfChaos
Created November 28, 2017 06:10
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save EssenceOfChaos/4befed247b2d3a0341fb6c8f41c67aa1 to your computer and use it in GitHub Desktop.
Save EssenceOfChaos/4befed247b2d3a0341fb6c8f41c67aa1 to your computer and use it in GitHub Desktop.
# /config/prod.exs on Heroku
use Mix.Config
# Configure for SSL
config :app, AppWeb.Endpoint,
load_from_system_env: true,
url: [scheme: "https", host: "https://app.herokuapp.com", port: 443],
force_ssl: [rewrite_on: [:x_forwarded_proto]],
cache_static_manifest: "priv/static/cache_manifest.json",
secret_key_base: Map.fetch!(System.get_env(), "SECRET_KEY_BASE")
# Configure your database
config :app, App.Repo,
adapter: Ecto.Adapters.Postgres,
url: System.get_env("DATABASE_URL"),
pool_size: String.to_integer(System.get_env("POOL_SIZE") || "10"),
ssl: true
# Do not print debug messages in production
config :logger, level: :info
# import_config "prod.secret.exs"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment