This commit is contained in:
anlicheng 2026-05-11 17:45:37 +08:00
parent 0fbafe4355
commit 92304770b7
49 changed files with 45 additions and 10 deletions

View File

@ -0,0 +1 @@
{erl_opts, [debug_info, {i, "include"}, {i, "../../include"}, {i, "../../../include"}]}.

View File

@ -0,0 +1,24 @@
{application, endpoint,
[{description, "Endpoint OTP application"},
{vsn, "0.1.0"},
{registered, [
endpoint_sup_sup,
endpoint_sup,
endpoint_subscription,
endpoint_log
]},
{mod, {endpoint_app, []}},
{applications, [
iot,
emqtt,
brod,
hackney,
gproc,
kernel,
stdlib
]},
{env, []},
{modules, []},
{licenses, ["Apache 2.0"]},
{links, []}
]}.

View File

@ -0,0 +1,15 @@
%%%-------------------------------------------------------------------
%% @doc endpoint application entrypoint.
%% @end
%%%-------------------------------------------------------------------
-module(endpoint_app).
-behaviour(application).
-export([start/2, stop/1]).
start(_StartType, _StartArgs) ->
endpoint_sup_sup:start_link().
stop(_State) ->
ok.

1
apps/iot/rebar.config Normal file
View File

@ -0,0 +1 @@
{erl_opts, [debug_info, {i, "include"}, {i, "../../include"}, {i, "../../../include"}]}.

View File

@ -46,15 +46,6 @@ init([]) ->
modules => ['udp_server']
},
#{
id => endpoint_sup_sup,
start => {'endpoint_sup_sup', start_link, []},
restart => permanent,
shutdown => 2000,
type => supervisor,
modules => ['endpoint_sup_sup']
},
#{
id => 'iot_host_sup',
start => {'iot_host_sup', start_link, []},

View File

@ -1,4 +1,6 @@
{erl_opts, [debug_info]}.
{erl_opts, [debug_info, {i, "include"}]}.
{project_app_dirs, ["apps/*"]}.
{deps, [
{poolboy, ".*", {git, "https://github.com/devinus/poolboy.git", {tag, "1.5.1"}}},
@ -14,6 +16,7 @@
{relx, [{release, {iot, "0.1.0"},
[iot,
endpoint,
sasl]},
{mode, dev},