1개 답변
- 최신
- 최다 투표
- 가장 많은 댓글
0
【以下的回答经过翻译处理】 你为什么要使用-S
选项来运行sudo呢?“read password from standard input”
只需运行sudo -E <命令>
即可。
你使用的sudo命令将不会作为ggc_user运行,而是作为root运行。
我不明白你的“部署一个可以复制的组件”的需求与你遇到的问题有什么关系。根据你提供的命令,你甚至还没有安装Greengrass,是吗?因此,你现在真正的需求只是安装和配置Greengrass。
要以root身份运行组件,请勿使用sudo。更新你的component recipe以指定RequiresPrivilege
。https://docs.aws.amazon.com/greengrass/v2/developerguide/component-recipe-reference.html
例如
Lifecycle:
Run:
Script: cp a_to_b b
RequiresPrivilege: true
관련 콘텐츠
- 질문됨 8달 전
- AWS 공식업데이트됨 9달 전