Last active
August 15, 2017 20:45
-
-
Save gjrevans/4e57a4087562af06d8f2668922995480 to your computer and use it in GitHub Desktop.
Run Phoenix in Production
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Initial setup | |
$ mix deps.get --only prod | |
$ MIX_ENV=prod mix compile | |
# Compile assets | |
$ brunch build --production | |
$ MIX_ENV=prod mix phoenix.digest | |
# Custom tasks (like DB migrations) | |
$ MIX_ENV=prod mix ecto.migrate | |
# Finally run the server | |
$ PORT=4001 MIX_ENV=prod mix phoenix.server |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment