Skip to content

Instantly share code, notes, and snippets.

View ziazek's full-sized avatar

Zek ziazek

View GitHub Profile
@ziazek
ziazek / prod.secret.exs
Last active June 1, 2017 08:49
Example Production secrets file
use Mix.Config
config :deploy_phoenix, DeployPhoenix.Endpoint,
secret_key_base: "<<SECRET_GOES_HERE>>"
# Configure your database
config :deploy_phoenix, DeployPhoenix.Repo,
adapter: Ecto.Adapters.Postgres,
username: "deployphoenix",
password: "mypassword",
@ziazek
ziazek / prod.exs
Last active June 1, 2017 08:30
config/prod.exs
# ...
config :deploy_phoenix, DeployPhoenix.Endpoint,
http: [port: 8888],
url: [host: "example.com", port: 80],
cache_static_manifest: "priv/static/manifest.json"
# ...
config :phoenix, :serve_endpoints, true
# ...
@ziazek
ziazek / config
Last active June 1, 2017 09:05
.deliver/config
APP="deploy_phoenix"
BUILD_HOST="188.166.182.170"
BUILD_USER="deploy"
BUILD_AT="/tmp/edeliver/$APP/builds"
RELEASE_DIR="/tmp/edeliver/$APP/builds/_build/prod/rel/$APP"
# prevent re-installing node modules; this defaults to "."
GIT_CLEAN_PATHS="_build rel priv/static"
def application do
[...,
applications: [..., :edeliver]]
end
defp deps do
[
...
{:edeliver, "~> 1.4.2"},
{:distillery, "~> 1.4"}]
@ziazek
ziazek / readmore.js
Created January 9, 2015 08:25
readmore.js
/*!
* @preserve
*
* Readmore.js jQuery plugin
* Author: @jed_foster
* Project home: http://jedfoster.github.io/Readmore.js
* Licensed under the MIT license
*
* Debounce function from http://davidwalsh.name/javascript-debounce-function
*/