diff --git a/priv/templates/src/wmskel.app.src b/priv/templates/src/wmskel.app.src index 9ddd22f7..c353cd27 100644 --- a/priv/templates/src/wmskel.app.src +++ b/priv/templates/src/wmskel.app.src @@ -8,6 +8,7 @@ {applications, [ kernel, stdlib, + inets, crypto, mochiweb, webmachine diff --git a/priv/templates/src/wmskel.erl b/priv/templates/src/wmskel.erl index fae6029d..2ef035ec 100644 --- a/priv/templates/src/wmskel.erl +++ b/priv/templates/src/wmskel.erl @@ -18,6 +18,7 @@ ensure_started(App) -> %% @spec start_link() -> {ok,Pid::pid()} %% @doc Starts the app for inclusion in a supervisor tree start_link() -> + ensure_started(inets), ensure_started(crypto), ensure_started(mochiweb), application:set_env(webmachine, webmachine_logger_module, @@ -28,7 +29,7 @@ start_link() -> %% @spec start() -> ok %% @doc Start the {{appid}} server. start() -> - inets:start(), + ensure_started(inets), ensure_started(crypto), ensure_started(mochiweb), application:set_env(webmachine, webmachine_logger_module, @@ -43,4 +44,5 @@ stop() -> application:stop(webmachine), application:stop(mochiweb), application:stop(crypto), + application:stop(inets), Res.