Merge pull request #9905 from zmstone/0203-disable-telemetry-for-ee-by-default
feat: disable telemetry for ee by default
This commit is contained in:
commit
71f8e10358
|
@ -4,13 +4,13 @@ concurrency:
|
|||
group: relup-${{ github.event_name }}-${{ github.ref }}
|
||||
cancel-in-progress: true
|
||||
|
||||
on:
|
||||
push:
|
||||
branches:
|
||||
- '**'
|
||||
tags:
|
||||
- e*
|
||||
pull_request:
|
||||
# on:
|
||||
# push:
|
||||
# branches:
|
||||
# - '**'
|
||||
# tags:
|
||||
# - e*
|
||||
# pull_request:
|
||||
|
||||
jobs:
|
||||
relup_test_plan:
|
||||
|
|
|
@ -0,0 +1 @@
|
|||
telemetry.enable = false
|
|
@ -30,7 +30,7 @@ main(_) ->
|
|||
case IsEnterprise of
|
||||
true ->
|
||||
EnterpriseCfgs = get_all_cfgs("lib-ee"),
|
||||
EnterpriseConf = merge("", EnterpriseCfgs),
|
||||
EnterpriseConf = merge(<<"">>, EnterpriseCfgs),
|
||||
ok = file:write_file("apps/emqx_conf/etc/emqx-enterprise.conf.all", EnterpriseConf);
|
||||
false ->
|
||||
ok
|
||||
|
@ -41,22 +41,21 @@ is_enterprise() ->
|
|||
nomatch =/= string:find(Profile, "enterprise").
|
||||
|
||||
merge(BaseConf, Cfgs) ->
|
||||
lists:foldl(
|
||||
fun(CfgFile, Acc) ->
|
||||
Confs = [BaseConf | lists:map(fun read_conf/1, Cfgs)],
|
||||
infix(lists:filter(fun(I) -> iolist_size(I) > 0 end, Confs), [io_lib:nl(), io_lib:nl()]).
|
||||
|
||||
read_conf(CfgFile) ->
|
||||
case filelib:is_regular(CfgFile) of
|
||||
true ->
|
||||
{ok, Bin1} = file:read_file(CfgFile),
|
||||
case string:trim(Bin1, both) of
|
||||
<<>> -> Acc;
|
||||
Bin2 -> [Acc, io_lib:nl(), io_lib:nl(), Bin2]
|
||||
end;
|
||||
string:trim(Bin1, both);
|
||||
false ->
|
||||
Acc
|
||||
end
|
||||
end,
|
||||
BaseConf,
|
||||
Cfgs
|
||||
).
|
||||
<<>>
|
||||
end.
|
||||
|
||||
infix([], _With) -> [];
|
||||
infix([One], _With) -> [One];
|
||||
infix([H | T], With) -> [H, With, infix(T, With)].
|
||||
|
||||
get_all_cfgs(Root) ->
|
||||
Apps0 = filelib:wildcard("*", Root) -- ["emqx_machine", "emqx_conf"],
|
||||
|
|
|
@ -14,8 +14,10 @@ export PROFILE
|
|||
|
||||
case $PROFILE in
|
||||
"emqx-enterprise")
|
||||
DIR='emqx-ee'
|
||||
EDITION='enterprise'
|
||||
#DIR='emqx-ee'
|
||||
#EDITION='enterprise'
|
||||
echo "No relup for now"
|
||||
exit 0
|
||||
;;
|
||||
"emqx")
|
||||
echo "No relup for opensource edition"
|
||||
|
|
Loading…
Reference in New Issue