-
Notifications
You must be signed in to change notification settings - Fork 2
SAM Deployment
loki-bedlam edited this page Mar 20, 2026
·
1 revision
Deploy Loki using the AWS Serverless Application Model (SAM) CLI.
- SAM CLI installed
sam deploy \
--template-file template.yaml \
--stack-name my-openclaw \
--region us-east-1 \
--parameter-overrides \
EnvironmentName=my-openclaw \
InstanceType=t4g.xlarge \
ModelMode=bedrock \
--capabilities CAPABILITY_NAMED_IAM CAPABILITY_AUTO_EXPAND \
--no-confirm-changesetOr use guided mode for interactive parameter input:
sam deploy --guided --template-file template.yamlThe SAM template uses Transform: AWS::Serverless-2016-10-31 and AWS::Serverless::Function for the Lambda custom resources. This means:
- SAM auto-generates IAM execution roles for Lambda functions (using
Policiesinstead of separateAWS::IAM::Roleresources) - Requires
CAPABILITY_AUTO_EXPANDin addition toCAPABILITY_NAMED_IAM - Otherwise identical infrastructure and parameters
Same as the CloudFormation template — InstanceId, PublicIp, SSMConnect, RoleArn, VpcId.
- No S3 bucket required — all Lambda code is inline (
InlineCode) - Stack creation takes ~8–10 minutes
- Use
sam delete --stack-name my-openclawto tear down