Is there a way to read the group name in a component or environment var?

0

I am using Greengrass V2 and I would like a way to read the current group the device belongs to. I don't need the group hierarchy but that would also be fine. Does anyone know if there is an environment variable for this? I can use the environment variable AWS_IOT_THING_NAME for the device name and I'm hoping there is something for group as well. If there isn't an environment variable is there a component level configuration that can be read, something like '{configuration:/DEPLOYMENT_GROUP}'?

Thanks

질문됨 3년 전260회 조회
2개 답변
0

Hi,

This is not currently supported. In the meantime, would you be able to use the ListThingGroupsForThing API to get the group name from the thing name?
https://docs.aws.amazon.com/iot/latest/developerguide/thing-groups.html#list-thing-groups-for-thing

Thanks,
AV

AWS
답변함 3년 전
0

Thanks for the suggestion. I think that will work for me.

답변함 3년 전

로그인하지 않았습니다. 로그인해야 답변을 게시할 수 있습니다.

좋은 답변은 질문에 명확하게 답하고 건설적인 피드백을 제공하며 질문자의 전문적인 성장을 장려합니다.

질문 답변하기에 대한 가이드라인

관련 콘텐츠