Changeset View
Changeset View
Standalone View
Standalone View
lib/kolab_chat/web/endpoint.ex
- This file was moved from lib/kolab_chat/endpoint.ex.
defmodule KolabChat.Endpoint do | defmodule KolabChat.Web.Endpoint do | ||||
use Phoenix.Endpoint, otp_app: :kolab_chat | use Phoenix.Endpoint, otp_app: :kolab_chat | ||||
socket "/socket", KolabChat.UserSocket | socket "/socket", KolabChat.Web.UserSocket | ||||
# Serve at "/" the static files from "priv/static" directory. | # Serve at "/" the static files from "priv/static" directory. | ||||
# | # | ||||
# You should set gzip to true if you are running phoenix.digest | # You should set gzip to true if you are running phoenix.digest | ||||
# when deploying your static files in production. | # when deploying your static files in production. | ||||
plug Plug.Static, | plug Plug.Static, | ||||
at: "/", from: :kolab_chat, gzip: false, | at: "/", from: :kolab_chat, gzip: false, | ||||
only: ~w(css fonts images js favicon.ico robots.txt) | only: ~w(css fonts images js favicon.ico robots.txt) | ||||
Show All 21 Lines | defmodule KolabChat.Web.Endpoint do | ||||
# this means its contents can be read but not tampered with. | # this means its contents can be read but not tampered with. | ||||
# Set :encryption_salt if you would also like to encrypt it. | # Set :encryption_salt if you would also like to encrypt it. | ||||
plug Plug.Session, | plug Plug.Session, | ||||
store: :cookie, | store: :cookie, | ||||
key: "_kolab_chat_key", | key: "_kolab_chat_key", | ||||
signing_salt: Keyword.get(Application.get_env(:kolab_chat, :salts), :session_signing), | signing_salt: Keyword.get(Application.get_env(:kolab_chat, :salts), :session_signing), | ||||
encryption_salt: Keyword.get(Application.get_env(:kolab_chat, :salts), :session_encryption) | encryption_salt: Keyword.get(Application.get_env(:kolab_chat, :salts), :session_encryption) | ||||
plug KolabChat.Router | plug KolabChat.Web.Router | ||||
end | end |