I have a parallel task in the step function that contains two branches. The input was:
{
"database": "test",
"userName": "tester",
"userID": "test123",
"adGroup": "testADGroup",
"dbGroup": "ReadGroup"
}
Run Code Online (Sandbox Code Playgroud)
Each branch return a json result like the following
Branch 1 (I used "OutputPath": "$"):
{
"requestType": "GrantAccess",
"DBUser": "exists",
"ADUser": "exists"
}
Run Code Online (Sandbox Code Playgroud)
Branch 2 (I used "ResultPath": "$.approvalStatus"):
{
"database": "test",
"userName": "tester",
"userID": "test123",
"adGroup": "testADGroup",
"dbGroup": "ReadGroup"
"approvalStatus": "Approved"
}
Run Code Online (Sandbox Code Playgroud)
When both the branches complete, the output of the …
我对 python 非常陌生,正在学习虚拟环境。我知道我应该将所有库安装在虚拟环境中并创建requirement.txt,以便其他人可以使用它进行安装。但是,我不确定部署到生产的最佳实践是什么?
我问的原因是,没有人应该有权访问生产环境,部署是通过预定义的管道进行的,我的理解是,它将压缩我的所有代码并将其部署到生产环境,没有人应该进入生产环境做任何体力工作。我可以尝试让管道运行脚本来安装基于requirement.txt的所有库,但我不确定防火墙设置是否相同。我也应该打包这些库吗?
另外,我应该如何触发python脚本?我是否应该有一个包装脚本来在调用 python 脚本之前激活 vevn 并在调用 python 脚本之后停用它?或者有更简单的方法吗?