diff options
author | Rina Fujino <18257209+rina23q@users.noreply.github.com> | 2021-09-21 09:50:40 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2021-09-21 09:50:40 +0200 |
commit | f55798a44456206d9beb31114d5b731ae74b50d1 (patch) | |
tree | a835f65977e0bcfe63a35e80ebf21d97f29edb8e /configuration/debian/tedge_agent | |
parent | f0c0ce160a2b191d72a30c5a97056dbb2a797837 (diff) |
[CIT-577] Update postinst script of tedge-agent (#436)
* [CIT-577] Update postinst script of tedge-agent
- tedge-agent can execute other plugins than apt
Signed-off-by: Rina Fujino <18257209+rina23q@users.noreply.github.com>
* [CIT-471] Add tests part 1
Signed-off-by: Rina Fujino <18257209+rina23q@users.noreply.github.com>
Diffstat (limited to 'configuration/debian/tedge_agent')
-rw-r--r-- | configuration/debian/tedge_agent/postinst | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/configuration/debian/tedge_agent/postinst b/configuration/debian/tedge_agent/postinst index 62df6779..437dc09f 100644 --- a/configuration/debian/tedge_agent/postinst +++ b/configuration/debian/tedge_agent/postinst @@ -13,10 +13,10 @@ if ! getent passwd tedge-agent > /dev/null; then fi ### Create file in /etc/sudoers.d directory -echo "%tedge-agent ALL = (ALL) NOPASSWD: /etc/tedge/sm-plugins/apt" > /etc/sudoers.d/tedge-agent +echo "%tedge-agent ALL = (ALL) NOPASSWD: /etc/tedge/sm-plugins/[a-zA-Z0-9]*" > /etc/sudoers.d/tedge-agent if [ -f "/etc/sudoers.d/010_pi-nopasswd" ]; then - echo "%tedge-agent ALL = (ALL) NOPASSWD: /etc/tedge/sm-plugins/apt" > /etc/sudoers.d/tedge-agent-nopasswd + echo "%tedge-agent ALL = (ALL) NOPASSWD: /etc/tedge/sm-plugins/[a-zA-Z0-9]*" > /etc/sudoers.d/tedge-agent-nopasswd fi # create /etc/tedge/.agent directory |