Lambda alias and deployments

0

Hi,

We are starting to use greengrass for our home automation device. I have a question regarding lambda version and the group deployment. I have associated the lambda to the core using an alias ("production" in our case). If I change the alias version number, do I have to create a deploy for each group? Can be this done automatically when I change the alias version number or do we have to create a script that creates a deployment for each group? And in this case, how can I understand which version of the lambda is deployed into the device without ssh into it? Because from the group and core the only thing I can see is the alias and not the associated version number.
For me makes a lot of sense to use an alias for each lambda. In this case we could create an alias "testing" to try new lambda version. But if the deployment is not done automatically and there is not way to see which version number is actually deployed to the device, I cannot see how it can be useful.
Maybe is just a matter of configuration that I have missed. I'm open to any suggestions.
I hope I have well explained my doubts.
Thank you very much for the replies!
Pier

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

Hi piergre:

We are happy to help you.

Question 1: If I change the alias version number, do I have to create a deploy for each group? Can be this done automatically when I change the alias version number or do we have to create a script that creates a deployment for each group?

Answer 2: Usually we point lambda alias to a lambda version, then that means whenever you create a new version of lambda(even through you have created a alias before), you still need to point your alias to your very last lambda version in lambda console and creates a deployment for each group.

Question 2:how can I understand which version of the lambda is deployed into the device without ssh into it

Answer 2: If you use a alias version, then without ssh into device, you can navigate to Greengrass console(IoT Core -> Greengrass on left panel -> Groups -> select <your_group> -> deployment -> lambdas)to check the alias version, but you will not see the version that this alias is pointing to, you have to go to lambda console to check which version this alias is pointing to now.

Thanks

AWS
답변함 3년 전
0

To add to the answer for question 1, yes you do need to re-deploy the associated greengrass groups if you change the version number for a certain alias. Re-deploying the group will copy the new lambda function onto the edge device. If you do not re-deploy, it will continue using the version number that you used during the last deployment.

답변함 3년 전

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

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

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

관련 콘텐츠