2 Star 10 Fork 5

lora/lorawan-server

加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
文件
克隆/下载
lorawan_server.config 2.49 KB
一键复制 编辑 原始数据 按行查看 历史
%%-*-erlang-*-
[
% server configuration
{lorawan_server, [
% UDP port listening for packets from the packet_forwarder Gateway
{packet_forwarder_listen, [{port, 1680}]},
% HTTP port for web-administration and REST API
{http_admin_listen, [{port, 8080}]},
% HTTP/SSL port
{http_admin_listen_ssl, [
{port, 8443},
{certfile, "cert.pem"},
{cacertfile, "cacert.pem"},
{keyfile, "key.pem"}
]},
% Enable this line for the Newly added cluster nodes
% {db_master, 'lorawan@yourhost'},
% redirect all http traffic to https (when both http and https are enabled)
{http_admin_redirect_ssl, true},
% default username and password for the admin interface
{http_admin_credentials, {<<"admin">>, <<"admin">>}},
% headers to be added to each HTTP response
{http_extra_headers, #{
% <<"access-control-allow-origin">> => <<"http://127.0.0.1:3000">>,
% <<"access-control-allow-credentials">> => <<"true">>,
% <<"access-control-allow-methods">> => <<"OPTIONS, GET, PUT, POST, DELETE">>,
% <<"access-control-allow-headers">> => <<"content-type">>,
% <<"access-control-expose-headers">> => <<"x-total-count">>
% <<"content-security-policy">> => <<"default-src * data: 'unsafe-inline' 'unsafe-eval';">>
}},
{http_custom_web, [
% enable this to serve additional web-pages
% {"/www", file, <<"/var/www/html/index.html">>, [{<<"anonymous">>, '*'}]},
% {"/www/[...]", dir, <<"/var/www/html">>, [{<<"anonymous">>, '*'}]}
]},
% Enable the following line to export statistics metrics in Prometheus format
% {enable_prometheus, true},
% amount of rxframes retained for each device/node
{retained_rxframes, 50},
% websocket expiration if client sends no data
{websocket_timeout, 3600000} % ms
]},
{os_mon, [
% Setting this parameter to true can be necessary on embedded systems with
% stripped-down versions of Unix tools like df.
{disksup_posix_only, false}
]},
% error logging settings
{lager, [
{colored, true},
% uncomment to display even a high number of messages per second
% see https://github.com/erlang-lager/lager#overload-protection
% {error_logger_hwm, undefined},
{handlers, [
% {lager_console_backend, [{level, debug}]},
{lager_file_backend, [{file, "debug.log"}, {level, debug}]},
{lager_file_backend, [{file, "error.log"}, {level, error}]}
]},
{crash_log, "crash.log"}
]},
{sasl, [
{errlog_type, error}
]}].
Loading...
马建仓 AI 助手
尝试更多
代码解读
代码找茬
代码优化
Erlang
1
https://gitee.com/mlora/lorawan-server.git
git@gitee.com:mlora/lorawan-server.git
mlora
lorawan-server
lorawan-server
master

搜索帮助