This change allow to set environment specific
to a widget in ${afm_confdir}/widget.env.d/ID/*
files where ID is the ID of the widget.
Setting specific environment for a given widget
was not possible (except in devel/debug) before.
Change-Id: I8ef9349fda9adb8eecf330ce97cc7ebcd21bf399
Signed-off-by: José Bollo <jose.bollo@iot.bzh>
if(NOT USE_SDK)
install(DIRECTORY DESTINATION ${afm_confdir}/unit.env.d)
+ install(DIRECTORY DESTINATION ${afm_confdir}/widget.env.d)
install(FILES ${CMAKE_CURRENT_BINARY_DIR}/afm-unit.conf DESTINATION ${afm_confdir})
endif()
%nl
[Service]
EnvironmentFile=-@afm_confdir@/unit.env.d/*
+EnvironmentFile=-@afm_confdir@/widget.env.d/{{:id}}/*
SmackProcessLabel=User::App::{{:id}}
SuccessExitStatus=0 SIGKILL
User=%i
%nl
[Service]
EnvironmentFile=-@afm_confdir@/unit.env.d/*
+EnvironmentFile=-@afm_confdir@/widget.env.d/{{:id}}/*
SmackProcessLabel=User::App::{{:id}}
SuccessExitStatus=0 SIGKILL
User=%i
[Service]
EnvironmentFile=-AFM_CONFIG_DIR/unit.env.d/*
+EnvironmentFile=-AFM_CONFIG_DIR/widget.env.d/{{:id}}/*
SmackProcessLabel=User::App::{{:id}}
SuccessExitStatus=0 SIGKILL