fix(schema): do not validate etc_dir
This commit is contained in:
parent
97e1cf65b7
commit
b1cf5bc1d4
|
@ -309,23 +309,7 @@ fields("node") ->
|
||||||
)}
|
)}
|
||||||
, {"etc_dir",
|
, {"etc_dir",
|
||||||
sc(string(),
|
sc(string(),
|
||||||
#{
|
#{ desc => "`etc` dir for the node"
|
||||||
converter => fun(EtcDir) ->
|
|
||||||
case filename:absname(EtcDir) =:= EtcDir of
|
|
||||||
true ->
|
|
||||||
unicode:characters_to_list(EtcDir);
|
|
||||||
false ->
|
|
||||||
unicode:characters_to_list(filename:join([code:lib_dir(), "..", EtcDir]))
|
|
||||||
end
|
|
||||||
end,
|
|
||||||
validator => fun(Path) ->
|
|
||||||
case filelib:is_dir(Path) of
|
|
||||||
true ->
|
|
||||||
ok;
|
|
||||||
false ->
|
|
||||||
error({not_dir, Path})
|
|
||||||
end
|
|
||||||
end
|
|
||||||
}
|
}
|
||||||
)}
|
)}
|
||||||
];
|
];
|
||||||
|
|
Loading…
Reference in New Issue