Skip to content

Commit

Permalink
Merge pull request webmachine#68 from basho/skel-priv-dir
Browse files Browse the repository at this point in the history
App skeleton priv dir
  • Loading branch information
vinoski committed May 1, 2012
2 parents 656aa69 + 53ee824 commit 8b2a7d5
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 3 deletions.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,2 +1,3 @@
deps/*
*.beam
.eunit/*
6 changes: 3 additions & 3 deletions priv/templates/src/wmskel_sup.erl
Original file line number Diff line number Diff line change
Expand Up @@ -42,9 +42,9 @@ upgrade() ->
%% @doc supervisor callback.
init([]) ->
Ip = case os:getenv("WEBMACHINE_IP") of false -> "0.0.0.0"; Any -> Any end,
{ok, Dispatch} = file:consult(filename:join(
[filename:dirname(code:which(?MODULE)),
"..", "priv", "dispatch.conf"])),
{ok, App} = application:get_application(?MODULE),
{ok, Dispatch} = file:consult(filename:join([code:priv_dir(App),
"dispatch.conf"])),
WebConfig = [
{ip, Ip},
{port, 8000},
Expand Down

0 comments on commit 8b2a7d5

Please sign in to comment.