Skip to content

Commit 993a76a

Browse files
committed
Update deployment workflows to use reusable patterns and enhance DEV deployment process
1 parent 6ff96aa commit 993a76a

1 file changed

Lines changed: 31 additions & 9 deletions

File tree

docs/DevOpsGuide.md

Lines changed: 31 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -36,13 +36,17 @@ The project utilizes the following workflows.
3636

3737
## Deployment Workflows
3838

39-
The project includes environment-specific deployment workflows that use GitHub Actions to deploy the application and infrastructure to AWS. Deployments require proper AWS credentials and environment variables to be configured.
39+
The project includes deployment workflows that use GitHub Actions to deploy the application and infrastructure to AWS. These workflows use a reusable workflow pattern to maintain consistency across environments. Deployments require proper AWS credentials and environment variables to be configured.
4040

41-
### Deploy to DEV
41+
### Deploy (Reusable)
4242

43-
**Workflow:** `deploy-dev.yml`
43+
**Workflow:** `deploy-reusable.yml`
44+
45+
A reusable workflow that provides the foundational deployment logic. This workflow is called by environment-specific deployment workflows and accepts the following inputs:
4446

45-
Manually triggered workflow that deploys the application and infrastructure to the DEV environment.
47+
- `aws_role_arn` (required): AWS IAM role ARN for credential assumption
48+
- `aws_region` (optional): AWS region (defaults to `us-east-1`)
49+
- `cdk_env` (required): CDK environment variables containing stack configuration
4650

4751
**Process:**
4852

@@ -51,11 +55,29 @@ Manually triggered workflow that deploys the application and infrastructure to t
5155
3. Configures AWS credentials via OIDC role assumption
5256
4. Installs and builds application code
5357
5. Runs all application tests
54-
6. Installs and builds infrastructure code
55-
7. Bootstraps CDK (if needed)
56-
8. Synthesizes CDK stacks
57-
9. Deploys all CDK stacks
58-
10. Cleans up sensitive files
58+
6. Installs infrastructure dependencies
59+
7. Creates `.env` file with CDK configuration
60+
8. Builds infrastructure code
61+
9. Bootstraps CDK (if needed)
62+
10. Synthesizes CDK stacks
63+
11. Deploys all CDK stacks using `npm run deploy:all -- --require-approval never --progress events`
64+
12. Cleans up sensitive files (`.env`, `cdk.out`)
65+
66+
### Deploy to DEV
67+
68+
**Workflow:** `deploy-dev.yml`
69+
70+
Environment-specific workflow that triggers the reusable deployment workflow for the DEV environment.
71+
72+
**Process:**
73+
74+
- Calls the reusable `deploy-reusable.yml` workflow
75+
- Passes DEV-specific configuration:
76+
- `AWS_ROLE_ARN_DEV` as the AWS role ARN
77+
- `AWS_REGION` as the AWS region
78+
- `CDK_ENV_DEV` as the CDK environment variables
79+
80+
**Concurrency:** Only one DEV deployment can run at a time; subsequent requests will cancel the in-progress workflow.
5981

6082
**Trigger:** Manual (`workflow_dispatch`)
6183

0 commit comments

Comments
 (0)