AWS Greengrass
Developer Guide

Create a Deployment

Now that your AWS Greengrass group is created and populated with a core definition, a device definition, a Lambda function definition, and a subscription definition, you can deploy the group configuration to your AWS Greengrass core device.

aws greengrass create-deployment --deployment-type NewDeployment --group-id GroupId --group-version-id GroupVersionId

Arguments for the create-deployment CLI command:


The type of deployment. Use NewDeployment for this example. Only NewDeployment and Redeployment can be used for the CreateDeployment command.


The group ID.


The group version ID of the group you want to deploy. Each group will have a version that corresponds to different group changes you have made.

The output of the create-deployment CLI command will look like this:

{ "DeploymentId": "4db95ef8-9309-4774-95a4-eea580b6ceef", "DeploymentArn": "arn:aws:greengrass:us-west-2:106511594199:/greengrass/groups/b744ed45-a7df-4227-860a-8d4492caa412/deployments/4db95ef8-9309-4774-95a4-eea580b6ceef" }

You can check the status of the deployment with the get-deployment-status CLI command:

aws greengrass get-deployment-status --deployment-id DeploymentId --group-id GroupId

Arguments for the get-deployment-status CLI command:


The deployment ID.


The group ID.

The output of the get-deployment-status CLI command will look like this:

{ "DeploymentStatus": "Success", "UpdatedAt": "2017-04-04T00:00:00.000Z" }

The DeploymentStatus is set to Building when the deployment is being prepared. When the deployment is ready but the AWS Greengrass core has not picked up the new deployment, the DeploymentStatus is InProgress.