interface RunAsProperty
Language | Type name |
---|---|
.NET | Amazon.CDK.AWS.Greengrass.CfnFunctionDefinitionVersion.RunAsProperty |
Java | software.amazon.awscdk.services.greengrass.CfnFunctionDefinitionVersion.RunAsProperty |
Python | aws_cdk.aws_greengrass.CfnFunctionDefinitionVersion.RunAsProperty |
TypeScript | @aws-cdk/aws-greengrass » CfnFunctionDefinitionVersion » RunAsProperty |
The user and group permissions used to run the Lambda function.
This setting overrides the default access identity that's specified for the group (by default, ggc_user and ggc_group). You can override the user, group, or both. For more information, see Run as in the Developer Guide .
Running as the root user increases risks to your data and device. Do not run as root (UID/GID=0) unless your business case requires it. For more information and requirements, see Running a Lambda Function as Root .
In an AWS CloudFormation template, RunAs
is a property of the Execution
property type.
Example
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import * as greengrass from '@aws-cdk/aws-greengrass';
const runAsProperty: greengrass.CfnFunctionDefinitionVersion.RunAsProperty = {
gid: 123,
uid: 123,
};
Properties
Name | Type | Description |
---|---|---|
gid? | number | The group ID whose permissions are used to run the Lambda function. |
uid? | number | The user ID whose permissions are used to run the Lambda function. |
gid?
Type:
number
(optional)
The group ID whose permissions are used to run the Lambda function.
You can use the getent group
command on your core device to look up the group ID.
uid?
Type:
number
(optional)
The user ID whose permissions are used to run the Lambda function.
You can use the getent passwd
command on your core device to look up the user ID.