<html>
<head>
<meta content="text/html; charset=KOI8-R" http-equiv="Content-Type">
</head>
<body text="#000000" bgcolor="#FFFFFF">
<div class="moz-cite-prefix">Hi Slava,<br>
<br>
Thanks for trying and setuping a github repo.<br>
<br>
Indeed, I tried with your code and it worked as expected without
any problem. This seemed rather strange since I had tried many
different combinations.<br>
<br>
From my findings, it seems that the main configuration must be
named `sys.config` unless what, it will spit out the error
message. To reproduce, rename `sys.config` to `app.config` and
restart erlang vm with `erl -config app`. When doing so, I get my
error message:<br>
<br>
{"could not start kernel pid",application_controller,"invalid
config data: invalid application name: \"custom\""}<br>
<br>
So, having a file named with a different name then `sys.config`
will prevent erlang from reading other referenced configuration
files.<br>
<br>
Don't know if I should do something more about this like asking
for feature request. Anyhow, thank you for solving this problem<br>
<br>
Regards,<br>
Matt<br>
<br>
On 2012-10-29 00:15, Slava Yurin wrote:<br>
</div>
<blockquote cite="mid:757551351484114@web16f.yandex.ru" type="cite">
<div>Hi Matthieu.</div>
<div></div>
<div>I used this feature without any problem.</div>
<div>Here my try<a class="moz-txt-link-freetext" href="https://github.com/nevar/sys_test">https://github.com/nevar/sys_test</a></div>
<div></div>
<div>24.10.2012, 21:03, "Matthieu Vachon"
<a class="moz-txt-link-rfc2396E" href="mailto:matthieu.ouellette-vachon@nuecho.com"><matthieu.ouellette-vachon@nuecho.com></a>:</div>
<blockquote type="cite">
<p>Hi All,<br>
<br>
In the config documentation page <br>
(<a moz-do-not-send="true"
href="http://www.erlang.org/doc/man/config.html">http://www.erlang.org/doc/man/config.html</a>),
it is noted that since <br>
R10B, the syntax of sys.config was extended to allow pointing
to other <br>
configuration files.<br>
<br>
[{Application, [{Par, Val}]} | File].<br>
<br>
So, I was wondering if this mechanism is supposed to work when
passing a <br>
config file via the command line parameter (i.e. -config):<br>
<br>
erl -boot boot_file -config sys<br>
<br>
I'm asking the question because in fact, I tried and I tried
and I tried <br>
without success. My config file looks like this:<br>
<br>
[<br>
{mnesia, [<br>
{dir, "db"}<br>
]},<br>
<br>
"/home/user/project/sys.user.config",<br>
].<br>
<br>
But anything I put as the File parameter result in an error. I
tried <br>
without the .config suffix, with a relative path, at the
beginning of <br>
the line, at the end. It always saying it's an invalid
application name. <br>
With this kind of error, I fear it works only in conjunction
with a full <br>
release and its not meant to work with config file passes as
command <br>
line arguments. Is it right?<br>
<br>
Here the full error message:<br>
<br>
could not start kernel pid (application_controller)
(invalid config <br>
data: invalid application name:
"/home/user/project/sys.user.config")<br>
<br>
Regards,<br>
Matt<br>
_______________________________________________<br>
erlang-questions mailing list<br>
<a moz-do-not-send="true"
href="mailto:erlang-questions@erlang.org">erlang-questions@erlang.org</a><br>
<a moz-do-not-send="true"
href="http://erlang.org/mailman/listinfo/erlang-questions">http://erlang.org/mailman/listinfo/erlang-questions</a></p>
</blockquote>
</blockquote>
<br>
</body>
</html>