-
Notifications
You must be signed in to change notification settings - Fork 96
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
6 changed files
with
118 additions
and
59 deletions.
There are no files selected for viewing
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,16 +1,18 @@ | ||
FROM msaraiva/elixir-dev:1.2.4 | ||
FROM elixir:1.5.2-alpine | ||
|
||
ENV APP_NAME poxa | ||
ENV MIX_ENV prod | ||
|
||
RUN apk --update add erlang-xmerl erlang-crypto erlang-sasl && rm -rf /var/cache/apk/* | ||
RUN apk --update add bash git erlang-xmerl erlang-crypto erlang-sasl && rm -rf /var/cache/apk/* | ||
|
||
COPY . /source | ||
WORKDIR /source | ||
|
||
RUN mix local.hex --force && mix local.rebar --force | ||
RUN MIX_ENV=prod mix deps.get | ||
RUN MIX_ENV=prod mix compile | ||
RUN MIX_ENV=prod mix release --verbosity=verbose --no-confirm-missing | ||
RUN mkdir /app && cp -r rel/$APP_NAME /app && rm -rf /source | ||
RUN mix deps.get | ||
RUN mix compile | ||
RUN mix release | ||
|
||
CMD trap exit TERM; /app/$APP_NAME/bin/$APP_NAME foreground & wait | ||
RUN mkdir /app && cp -r _build/prod/rel/$APP_NAME /app && rm -rf /source | ||
|
||
CMD /app/$APP_NAME/bin/$APP_NAME foreground |
This file contains 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
This file was deleted.
Oops, something went wrong.
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,44 @@ | ||
# HTTP Port | ||
# If not set, will use value of PORT environment variable | ||
poxa.port = 8080 | ||
|
||
# Pusher app key | ||
# If not set, will use value of POXA_APP_KEY environment variable | ||
poxa.app_key = "app_key" | ||
|
||
# Pusher secret | ||
# If not set, will use value of POXA_SECRET environment variable | ||
poxa.app_secret = "secret" | ||
|
||
# Pusher app id | ||
# If not set, will use value of POXA_APP_ID environment variable | ||
poxa.app_id = "app_id" | ||
|
||
# Registry adapter | ||
# If not set, will use value of POXA_REGISTRY_ADAPTER environment variable | ||
poxa.registry_adapter = "gproc" | ||
|
||
# Web hook endpoint | ||
# If not set, will use value of WEB_HOOK environment variable | ||
# poxa.web_hook = | ||
|
||
# HTTPS switch | ||
# If not set, will use value of POXA_SSL environment variable | ||
poxa.ssl.enabled = false | ||
|
||
# HTTPS port | ||
# If not set, will use value of SSL_PORT environment variable | ||
# poxa.ssl.port = | ||
|
||
# PEM-encoded CA certificate path | ||
# If not set, will use value of SSL_CACERTFILE environment variable | ||
# poxa.ssl.cacertfile = | ||
|
||
# Path to user certificate | ||
# If not set, will use value of SSL_CERTFILE environment variable | ||
# poxa.ssl.certfile = | ||
|
||
# Path to the file containing the user's private PEM-encoded key | ||
# If not set, will use value of SSL_KEYFILE environment variable | ||
# poxa.ssl.keyfile = | ||
|
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,75 +1,97 @@ | ||
[ | ||
extends: [], | ||
import: [], | ||
mappings: [ | ||
"poxa.port": [ | ||
doc: "HTTP port", | ||
to: "poxa.port", | ||
commented: false, | ||
datatype: :integer, | ||
default: 8080 | ||
default: 8080, | ||
doc: "HTTP Port", | ||
hidden: false, | ||
env_var: "PORT", | ||
to: "poxa.port" | ||
], | ||
"poxa.app_key": [ | ||
doc: "Pusher app key", | ||
to: "poxa.app_key", | ||
commented: false, | ||
datatype: :binary, | ||
default: "app_key" | ||
default: "app_key", | ||
doc: "Pusher app key", | ||
hidden: false, | ||
env_var: "POXA_APP_KEY", | ||
to: "poxa.app_key" | ||
], | ||
"poxa.app_secret": [ | ||
doc: "Pusher secret", | ||
to: "poxa.app_secret", | ||
commented: false, | ||
datatype: :binary, | ||
default: "secret" | ||
default: "secret", | ||
doc: "Pusher secret", | ||
hidden: false, | ||
env_var: "POXA_SECRET", | ||
to: "poxa.app_secret" | ||
], | ||
"poxa.app_id": [ | ||
doc: "Pusher app id", | ||
to: "poxa.app_id", | ||
commented: false, | ||
datatype: :binary, | ||
default: "app_id" | ||
default: "app_id", | ||
doc: "Pusher app id", | ||
hidden: false, | ||
env_var: "POXA_APP_ID", | ||
to: "poxa.app_id" | ||
], | ||
"poxa.registry_adapter": [ | ||
commented: false, | ||
datatype: :binary, | ||
default: "gproc", | ||
doc: "Registry adapter", | ||
hidden: false, | ||
env_var: "POXA_REGISTRY_ADAPTER", | ||
to: "poxa.registry_adapter" | ||
], | ||
"poxa.web_hook": [ | ||
commented: true, | ||
datatype: :atom, | ||
commented: false, | ||
datatype: :binary, | ||
doc: "Web hook endpoint", | ||
hidden: false, | ||
default: "", | ||
env_var: "WEB_HOOK", | ||
to: "poxa.web_hook" | ||
], | ||
], | ||
"poxa.ssl.enabled": [ | ||
doc: "HTTPS switch", | ||
to: "poxa.ssl.enabled", | ||
datatype: :boolean, | ||
env_var: "POXA_SSL", | ||
default: false, | ||
], | ||
"poxa.ssl.port": [ | ||
doc: "HTTPS port", | ||
to: "poxa.ssl.port", | ||
env_var: "SSL_PORT", | ||
default: 8443, | ||
datatype: :integer, | ||
], | ||
"poxa.ssl.cacertfile": [ | ||
doc: "PEM-encoded CA certificate path", | ||
to: "poxa.ssl.cacertfile", | ||
env_var: "SSL_CACERTFILE", | ||
default: "", | ||
datatype: :binary, | ||
], | ||
"poxa.ssl.certfile": [ | ||
doc: "Path to user certificate", | ||
to: "poxa.ssl.certfile", | ||
env_var: "SSL_CERTFILE", | ||
default: "", | ||
datatype: :binary, | ||
], | ||
"poxa.ssl.keyfile": [ | ||
doc: "Path to the file containing the user's private PEM-encoded key", | ||
to: "poxa.ssl.keyfile", | ||
env_var: "SSL_KEYFILE", | ||
default: "", | ||
datatype: :binary, | ||
] | ||
], | ||
translations: [ | ||
] | ||
transforms: [], | ||
validators: [] | ||
] |
This file was deleted.
Oops, something went wrong.