[AWS] stepfunctions-local

本质是本地docker,只支持异步调用

  1. run aws-stepfunctions-local

    docker run -p 8083:8083
    --mount type=bind,readonly,source=/path/MockConfigFile.json,destination=/home/StepFunctionsLocal/MockConfigFile.json
    -e SFN_MOCK_CONFIG="/home/StepFunctionsLocal/MockConfigFile.json"
    --env-file /path/aws-stepfunctions-local-credentials.txt
    amazon/aws-stepfunctions-local

  2. Create a state machine

    aws stepfunctions create-state-machine --endpoint-url http://localhost:8083
    --name "sf-noDependencies"
    --definition "{"Comment":"A description of my state machine","StartAt":"Pass","States":{"Pass":{"Type":"Pass","Next":"Success","Result":{"output":"hello word"}},"Success":{"Type":"Succeed"}}}"
    --role-arn "arn:aws:iam::012345678901:role/DummyRole"

    return
    {
    "stateMachineArn": "arn:aws:states:us-east-1:123456789012:stateMachine:sf-noDependencies",
    "creationDate": "2024-04-23T09:21:28.168000+08:00"
    }

  • run sf-noDependencies

    aws stepfunctions start-execution --endpoint-url http://localhost:8083 --state-machine-arn arn:aws:states:us-east-1:123456789012:stateMachine:sf-noDependencies

    return
    {
    "executionArn": "arn:aws:states:us-east-1:123456789012:execution:sf-noDependencies:37c65018-25db-4d92-9aee-6e319b1cf5b7",
    "startDate": "2024-04-22T15:08:15.401000+08:00"
    }

  • describe-execution

    aws stepfunctions describe-execution --endpoint http://localhost:8083 --execution-arn arn:aws:states:us-east-1:123456789012:execution:sf-noDependencies:37c65018-25db-4d92-9aee-6e319b1cf5b7

相关推荐
szqcloud5 小时前
腾讯云SDK基本概念
云计算·音视频·腾讯云
lfsun6665 小时前
【60天备战2024年11月软考高级系统架构设计师——第30天:云计算与大数据架构——云计算架构设计原则】
大数据·系统架构·云计算
yidiancaijing7 小时前
云栖大会观察:云计算第三次浪潮下的暗流涌动
阿里云·云计算·云栖大会
打地基的小白7 小时前
QT+ESP8266+STM32项目构建三部曲二--阿里云云端处理之云产品流转
阿里云·云计算·上位机与下位机的转接
superman超哥8 小时前
Docker从入门到精通_01 Docker:引领云计算的新浪潮
docker·容器·云计算
大模型实战8 小时前
阿里云百炼SFT微调实践
人工智能·算法·阿里云·云计算
小安运维日记8 小时前
Linux云计算 |【第四阶段】RDBMS1-DAY2
linux·运维·服务器·mysql·云计算
Dovir多多1 天前
web服务器运维常用技巧总结
运维·服务器·ubuntu·docker·centos·云计算·web
小安运维日记1 天前
Linux云计算 |【第四阶段】RDBMS1-DAY1
linux·运维·云计算
mqiqe1 天前
云计算Openstack
云计算·openstack