step#
Developer note:
every function in the
step.pymodule should have visualized logging.
- aws_ops_alpha.project.simple_lbd_agw_chalice.step.download_deployed_json(semantic_branch_name: str, runtime_name: str, env_name: str, bsm_devops: BotoSesManager, pyproject_ops: pyops.PyProjectOps, s3path_deployed_json: S3Path, check=True, step: str = 'DEPLOY_CHALICE_APP', truth_table: Optional[TruthTable] = None, url: Optional[str] = None) bool[source]#
See
aws_ops_alpha.aws_helpers.aws_chalice_helpers.download_deployed_json().- Parameters:
semantic_branch_name – semantic branch name for conditional step test.
runtime_name – runtime name for conditional step test.
env_name – env name, will be used for conditional step test.
bsm_devops – the devops AWS Account
BotoSesManagerobject.pyproject_ops –
PyProjectOpsobject.s3path_deployed_json – the S3 path to the deployed
${env_name}.jsonfile.check – whether to check if we should run this step.
step – step name for conditional step test.
truth_table – truth table for conditional step test.
url – print the Google sheet url when conditional step test failed.
- aws_ops_alpha.project.simple_lbd_agw_chalice.step.upload_deployed_json(semantic_branch_name: str, runtime_name: str, env_name: str, bsm_devops: BotoSesManager, pyproject_ops: pyops.PyProjectOps, s3path_deployed_json: S3Path, source_sha256: Optional[str] = None, tags: Optional[Dict[str, str]] = None, check=True, step: str = 'DEPLOY_CHALICE_APP', truth_table: Optional[TruthTable] = None, url: Optional[str] = None) bool[source]#
See
aws_ops_alpha.aws_helpers.aws_chalice_helpers.upload_deployed_json().- Parameters:
semantic_branch_name – semantic branch name for conditional step test.
runtime_name – runtime name for conditional step test.
env_name – env name, will be used for conditional step test.
bsm_devops – the devops AWS Account
BotoSesManagerobject.pyproject_ops –
PyProjectOpsobject.s3path_deployed_json – the S3 path to the deployed
${env_name}.jsonfile.tags – optional AWS resource tags.
check – whether to check if we should run this step.
step – step name for conditional step test.
truth_table – truth table for conditional step test.
url – print the Google sheet url when conditional step test failed.
- aws_ops_alpha.project.simple_lbd_agw_chalice.step.get_lock(vault: Vault, owner: str, bsm_devops: BotoSesManager) Optional[Lock][source]#
Get the concurrency lock.
- Returns:
True if got the lock, False if not.
- aws_ops_alpha.project.simple_lbd_agw_chalice.step.run_chalice_deploy(semantic_branch_name: str, runtime_name: str, env_name: str, chalice_app_name: str, bsm_devops: BotoSesManager, bsm_workload: BotoSesManager, pyproject_ops: pyops.PyProjectOps, s3path_deployed_json: S3Path, tags: Optional[Dict[str, str]] = None, check=True, step: str = 'DEPLOY_CHALICE_APP', truth_table: Optional[TruthTable] = None, url: Optional[str] = None) bool[source]#
Deploy lambda app using chalice.
The workflow is as follows:
build lambda source code for
lambda_app/vendor/${package_name}folder.run
update_chalice_config.pyscript to update.chalice/config.jsonfile.download the
lambda_app/.chalice/deployed/${env_name}.jsonfile.run
chalice deploycommand to deploy the lambda function.upload the
lambda_app/.chalice/deployed/${env_name}.jsonfile.
- Parameters:
semantic_branch_name – semantic branch name for conditional step test.
runtime_name – runtime name for conditional step test.
env_name – env name, will be used for conditional step test.
chalice_app_name – the chalice app name, it will be used as part of the lambda function naming convention.
bsm_devops – the devops AWS Account
BotoSesManagerobject.bsm_workload – the workload AWS Account
BotoSesManagerobject.pyproject_ops –
PyProjectOpsobject.s3path_deployed_json – the S3 path to the deployed
${env_name}.jsonfile.tags – optional AWS resource tags.
check – whether to check if we should run this step.
step – step name for conditional step test.
truth_table – truth table for conditional step test.
url – print the Google sheet url when conditional step test failed.
- Returns:
a boolean flag to indicate whether it runs
chalice deploycommand.
- aws_ops_alpha.project.simple_lbd_agw_chalice.step.run_chalice_delete(semantic_branch_name: str, runtime_name: str, env_name: str, chalice_app_name: str, bsm_devops: BotoSesManager, bsm_workload: BotoSesManager, pyproject_ops: pyops.PyProjectOps, s3path_deployed_json: S3Path, tags: Optional[Dict[str, str]] = None, check=True, step: str = 'DELETE_CHALICE_APP', truth_table: Optional[TruthTable] = None, url: Optional[str] = None) bool[source]#
Delete lambda app using chalice.
The workflow is as follows:
create dummy
.chalice/config.jsonfile.download the
lambda_app/.chalice/deployed/${env_name}.jsonfile.run
chalice deletecommand to delete the lambda function.upload the
lambda_app/.chalice/deployed/${env_name}.jsonfile.
- Parameters:
semantic_branch_name – semantic branch name for conditional step test.
runtime_name – runtime name for conditional step test.
env_name – env name, will be used for conditional step test.
chalice_app_name – the chalice app name, it will be used as part of the lambda function naming convention.
bsm_devops – the devops AWS Account
BotoSesManagerobject.bsm_workload – the workload AWS Account
BotoSesManagerobject.pyproject_ops –
PyProjectOpsobject.s3path_deployed_json – the S3 path to the deployed
${env_name}.jsonfile.tags – optional AWS resource tags.
check – whether to check if we should run this step.
step – step name for conditional step test.
truth_table – truth table for conditional step test.
url – print the Google sheet url when conditional step test failed.
- Returns:
a boolean flag to indicate whether it runs
chalice deletecommand.