Setting Configuration Options for Step Functions Local - Amazon Step Functions
Services or capabilities described in Amazon Web Services documentation might vary by Region. To see the differences applicable to the China Regions, see Getting Started with Amazon Web Services in China (PDF).

Setting Configuration Options for Step Functions Local

When you start Amazon Step Functions Local by using the JAR file, you can set configuration options by using the Amazon Command Line Interface (Amazon CLI), or by including them in the system environment. For Docker, you must specify these options in a file that you reference when starting Step Functions Local.

Configuration Options

When you configure the Step Functions Local container to use an override endpoint such as Lambda Endpoint and Batch Endpoint, and make calls to that endpoint, Step Functions Local doesn't use the credentials you specify. Setting these endpoint overrides is optional.

Option Command Line Environment
Account -account, --aws-account AWS_ACCOUNT_ID
Region -region, --aws-region AWS_DEFAULT_REGION
Wait Time Scale -waitTimeScale, --wait-time-scale WAIT_TIME_SCALE
Lambda Endpoint -lambdaEndpoint, --lambda-endpoint LAMBDA_ENDPOINT
Batch Endpoint -batchEndpoint, --batch-endpoint BATCH_ENDPOINT
DynamoDB Endpoint -dynamoDBEndpoint, --dynamodb-endpoint DYNAMODB_ENDPOINT
ECS Endpoint -ecsEndpoint, --ecs-endpoint ECS_ENDPOINT
Glue Endpoint -glueEndpoint, --glue-endpoint GLUE_ENDPOINT
SageMaker Endpoint -sageMakerEndpoint, --sagemaker-endpoint SAGE_MAKER_ENDPOINT
SQS Endpoint -sqsEndpoint, --sqs-endpoint SQS_ENDPOINT
SNS Endpoint -snsEndpoint, --sns-endpoint SNS_ENDPOINT
Step Functions Endpoint -stepFunctionsEndpoint, --step-functions-endpoint STEP_FUNCTIONS_ENDPOINT

Credentials and configuration for Docker

To configure Step Functions Local for Docker, create the following file: aws-stepfunctions-local-credentials.txt.

This file contains your credentials and other configuration options. The following can be used as a template when creating the aws-stepfunctions-local-credentials.txt file.

AWS_DEFAULT_REGION=AWS_REGION_OF_YOUR_AWS_RESOURCES AWS_ACCESS_KEY_ID=YOUR_AWS_ACCESS_KEY AWS_SECRET_ACCESS_KEY=YOUR_AWS_SECRET_KEY WAIT_TIME_SCALE=VALUE LAMBDA_ENDPOINT=VALUE BATCH_ENDPOINT=VALUE DYNAMODB_ENDPOINT=VALUE ECS_ENDPOINT=VALUE GLUE_ENDPOINT=VALUE SAGE_MAKER_ENDPOINT=VALUE SQS_ENDPOINT=VALUE SNS_ENDPOINT=VALUE STEP_FUNCTIONS_ENDPOINT=VALUE

Once you have configured your credentials and configuration options in aws-stepfunctions-local-credentials.txt, start Step Functions with the following command.

docker run -p 8083:8083 --env-file aws-stepfunctions-local-credentials.txt amazon/aws-stepfunctions-local
Note

It is recommended to use the special DNS name host.docker.internal, which resolves to the internal IP address that the host uses, such as http://host.docker.internal:8000. For more information, see Docker documentation for Mac and Windows at Networking features in Docker Desktop for Mac and Networking features in Docker Desktop for Windows respectively.