aws-iot-greengrass

Installation
SKILL.md

Overview

AWS IoT Greengrass is an edge runtime for IoT devices. This skill covers experimentation and quick start scenarios in containerized environments — not production deployments.

Two runtimes are available:

  • Greengrass Nucleus — Full Java runtime with complete component lifecycle management and IPC support
  • Greengrass Nucleus Lite — Lightweight C runtime for constrained devices (<5MB RAM), optimized for minimal footprint

When a user doesn't specify which runtime, always ask before proceeding.

When to Use This Skill

Use this skill when:

  • Setting up Greengrass Nucleus or Lite in containers for experimentation
  • Creating or deploying custom IoT components
  • Migrating Greengrass V1 Lambda functions to V2 components
  • Troubleshooting Greengrass container or component issues
  • Working with Greengrass IPC, MQTT, or component recipes

Do NOT use this skill for:

  • Production device provisioning or fleet management
  • AWS IoT Core without Greengrass (use IoT Core docs directly)
  • Other edge runtimes (AWS IoT SiteWise, FreeRTOS, etc.)

Workflow Selection

Choose the right starting point:

Setup

Component Development

Migration

Troubleshooting

Common Mistakes

Avoid these frequent errors when working with Greengrass:

  1. Using Run instead of run in Lite recipes: Greengrass Lite is case-sensitive for all recipe lifecycle keys. Use lowercase: run, install, startup, shutdown.

  2. Deploying to individual things instead of thing groups: Greengrass Lite requires deployments to target thing groups, not individual things. Always create a thing group and deploy to the group ARN.

  3. Using boto3 for IoT Core publishing: Never use boto3 to publish to IoT Core from Greengrass components. Use GreengrassCoreIPCClientV2 from the awsiotsdk package instead.

  4. Using string QoS values: QoS must be numeric (0, 1, 2), not strings like "AT_LEAST_ONCE".

  5. Missing Token Exchange Service dependency: Components accessing AWS services (S3, DynamoDB, etc.) must declare aws.greengrass.TokenExchangeService as a hard dependency in the recipe.

  6. Including AWS CLI in containers: Don't install AWS CLI in Greengrass containers. Use static configuration with pre-fetched IoT endpoints instead — this reduces image size by ~67% and startup time by ~75%.

  7. Running Greengrass Nucleus as non-root: The full Nucleus runtime requires root privileges in containers. Use --init --privileged flags. (Lite uses ggcore user instead.)

  8. Forgetting flush=True in Python print statements: Component logs won't appear in systemd journal without explicit output flushing.

Defaults

Use these unless the user specifies otherwise:

  • Container runtime: Podman (preferred over Docker)
  • Region: us-east-1
  • Working directory: /tmp/ for setup files and configurations
  • Component language: Python
  • Deployment method: Cloud deployment (preferred over local for full AWS experience)
  • Recipe format: YAML (easier for local development than JSON)

LLM Context Files

For up-to-date API and service documentation (covers both Nucleus and Lite):

Reference Files

Load these as needed for detailed implementation guidance:

Installs
11
GitHub Stars
11
First Seen
Mar 10, 2026