Coder Social home page Coder Social logo

aws-greengrass-developer-guide's Introduction

aws-greengrass-developer-guide's People

Contributors

buzzsurfr avatar catechs avatar dkdiaz avatar dmantula avatar feiyxaws avatar fthompsonaws avatar hyandell avatar joshbean avatar kumpmati avatar nenadilic84 avatar rashmise avatar ret avatar richa-aws avatar str3tch avatar timmattison avatar ygefen avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

aws-greengrass-developer-guide's Issues

Generic Greengrass IoT policy using policy variables

The Minimal Greengrass IoT policy documented in https://github.com/awsdocs/aws-greengrass-developer-guide/blame/master/doc_source/device-auth.md#L112 provides a sample policy that requires you to hard-code the Thing Names and Greengrass Group IDs into the policy statements.

It would be very helpful to add an example of a generic policy that uses IoT policy variables like ${iot:Connection.Thing.ThingName} and ${iot:Connection.Thing.Attributes[greengrassGroupId]} to avoid hard-coding the Thing Names and Greengrass Group IDs. Such a policy could be shared by all deployed Greengrass Cores, eliminating the need to deploy hundreds or thousands of separate policies.

I have been developing such a policy myself recently and it's very difficult to get it right. As a developer there is no visibility to what the current values of policy variables are and debugging is a lot of trial-and-error work. Therefore it would be quite valuable to have an AWS-provided example as a reference.

The greengrass:Discover permission is not included in the example policy

We spent a lot of time debugging why our IoT policy, based on the "minimal AWS IoT Policy for Greengrass" (https://github.com/awsdocs/aws-greengrass-developer-guide/blob/master/doc_source/device-auth.md) did not allow our Docker services to discover the Greengrass endpoint.

The reason turned out to be that greengrass:Discover is not included in the minimal example policy. It includes greengrass:GetConnectivityInfo, so we thought that would be enough to allow the services to perform discovery. We completely missed that greengrass:Discover was even mentioned in the documentation.

Since many developers probably copy and adapt the example policy, I would suggest either adding the greengrass:Discover permission to it, or at least adding a note reminding that you will also need greengrass:Discover if you want to perform discovery.

Note that we are using a shared IoT policy that covers both our Greengrass Core and the Docker services running as "devices" in the Greengrass Group. I don't know if this is a normal use case, but we certainly don't want to create even more separate IoT policies for all the Docker containers running on every device.

PS. To add some difficulty, greengrass:Discover is also not included in this documentation: https://docs.aws.amazon.com/IAM/latest/UserGuide/list_awsiotgreengrass.html#awsiotgreengrass-actions-as-permissions. So it's pretty difficult to spot it when you don't even realize it exists.

Access denied trying to update Greengrass Core with CLI

I am trying the update the Greengrass Core on a device. Upon running the command:

aws greengrass create-software-update-job     --update-targets-architecture armv7l     --update-targets arn:aws:iot:eu-west-1:MYACCOUNTID:thing/raspberrydnb1_Core     --update-targets-operating-system raspbian     --software-to-update core     --s3-url-signer-role arn:aws:iam::MYACCOUNTID:role/service-role/Greengrass_ServiceRole     --update-agent-log-level WARN

I get an error:

An error occurred (InvalidRequestException) when calling the
CreateSoftwareUpdateJob operation: Permission denied when attempting
to assume role arn:aws:iam::MYACCOUNTID:role/GreenGrassUpdateRole.

My trust policy on the signer role is like:

{
      "Effect": "Allow",
      "Principal": {
        "AWS": "arn:aws:iam::MYACCOUNTID:root",
        "Service": "greengrass.amazonaws.com"
      },
      "Action": "sts:AssumeRole"
    }

By the way, this command works:

aws sts assume-role --role-arn arn:aws:iam::MYACCOUNTID:role/GreenGrassUpdateRole --role-session-name example-role-assume

ML Inference on Raspberry Pi requires 2.5 A power source

The inference instructions should note that running deep learning frameworks on a Raspberry Pi requires a 2.5A power source. If you use a lower rated power supply, the Pi will likely reboot whenever you try to perform inference by running the forward method on the network, at least for deep networks that you see with image use cases. I saw this behavior with MxNet, the DLR, and TensorFlow on a Pi 3B+.

aws iot greengrass on jetson nano - local resource access failed

Hi,

I'm trying to implement aws greengrass on jetson nano I'm following below aws documentation;
https://docs.aws.amazon.com/greengrass/latest/developerguide/lra-console.html

But i can't able to proceed or having issue read/write a file from cloud to edge. Im having spending more a days, didn't find and can't able fix this issue. Please help me out!!!
Here is my log while lambda running;

[2019-07-01T15:57:47.009+05:30][INFO]-lambda_runtime.py:331,Caught signal 15. Stopping runtime.
[2019-07-01T15:57:59.286+05:30][INFO]-lambda_runtime.py:114,Running [arn:aws:lambda:us-east-1:xxxxxxxxxx:function:TestLRA:7]
[2019-07-01T15:57:59.286+05:30][INFO]-ipc_client.py:170,Getting work for function [arn:aws:lambda:us-east-1:xxxxxxxxxxx:function:TestLRA:7] from http://localhost:8000/2016-11-01/functions/arn:aws:lambda:us-east-1:xxxxxxxxxxx:function:TestLRA:7/work

Could not find suitable distribution for Requirement.parse('dlr==1.0')

Hi there,
Could you help me to take a look? Thank you!

Documentation:
Configure Optimized Machine Learning Inference Using the AWS Management Console

Problem Description:

  1. Operating system: Raspbian for Raspberry Pi 3B+

  2. Problem at Step 2.7 Install the Neo deep learning runtime

  3. The error I got: 'No local packages or working download links found for dlr==1.0
    error: Could not find suitable distribution for Requirement.parse('dlr==1.0')'

  4. I also tried installation using the below two ways but neither worked.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.