Deploy via GitHub Actions
MCE-3 Order: #3 Datalake Formation Has Dependencies
Updated 1 month, 2 weeks ago
Guidance
Purpose
Deploy the CDK app through GitHub Actions with OIDC. Production path for a GitHub-hosted lake repo.
Inputs
- Lake Scope Contract (
cimust begithub_actions). - CDK Application (includes DeployStack).
- Starter
.github/workflows/deploy.yml— copy from the clone; do not invent a second pipeline. Template:https://github.com/FeatureFactory-io/ops-lake-starter/blob/main/.github/workflows/deploy.yml. - Skill GitHub Actions CI/CD → Recipe.
Skip when
ci is gitlab_ci. Do not create deploy.yml "just in case".
Steps
- Keep starter
.github/workflows/deploy.yml. - Chicken-and-egg: laptop, same region as the contract:
cdk bootstrapthencdk deploy OpsLakeDeploy(or--all) once. ReadDeployRoleArnfrom stack outputs. GitHub → Settings → Secrets and variables → Actions → New repository secretAWS_DEPLOY_ROLE_ARN. AlsoOPSLAKE_GITHUB_PAT(repo,read:org). NeverGITHUB_*. After that, nevercdk deploya shared env from a laptop. permissions: id-token: write. Assume the deploy role viaaws-actions/configure-aws-credentials. NoAWS_ACCESS_KEY_ID.- Jobs: pytest →
cdk deploy --all --require-approval never. PrintDeployRoleArn,GithubWebhookUrl,StreamlitMartUrlto the job summary. IAM simulate Streamlit task-role S3 read. - OIDC trust both
repo:{org}/{lake_repo}:*andrepo:{org}@*/{lake_repo}@*:*. Amainpush AssumeRoleWithWebIdentity must succeed (check the Actions log). - After first GHA deploy, record URLs/ARNs in
docs/deploy-manifest.yaml. Org webhook registration is the next human step (activity Stand Up Serverless Ingestion) — deploy does not by itself land events.
Done when
- Workflow file is the only shared-env deploy path.
- OIDC covers both
subshapes;AWS_DEPLOY_ROLE_ARNis set.
Feeds
Pipeline + populate-lake. Shared-env resources appear only after this workflow runs on main.
Details
- Order:
- #3
- Phase:
- Predecessor:
- MCE-2 Model the Data Lake as CDK Stacks
- Created:
- Aug 31, 2026
- Last Updated:
- Sep 17, 2026
Workflow
Model and Deploy Infrastructure as Code
Lock the lake's scope and stand the AWS estate up as code so every later step lands on the same …
View WorkflowAssigned Agent
Data Platform Engineer
Agent: Data Platform Engineer Role Owns Datalake Formation: Scope Contract → Python CDK (DeployStack + …
Required Skills
- GitHub Actions CI/CD DevOps / CI-CD GitHub Actions, OIDC
Rules
-
Execute by Workflow Order
execute-by-step-labels -
GitHub OIDC Trust Both Sub Shapes
github-oidc-trust-both-sub-shapes -
Infrastructure as Code First
infrastructure-as-code-first -
Never Name GitHub Actions Secrets GITHUB_*
never-name-gha-secrets-github-prefix
Input Artifacts 3
-
CDK Application (Infrastructure Stacks)
Document
Required
Produced by: Model the Data Lake as CDK Stacks -
Lake Scope Contract
Document
Required
Produced by: Scope Sources, Org, and Environment -
OIDC Deploy Role (GitHub Actions)
Document
Required
Produced by: Model the Data Lake as CDK Stacks
Output Artifacts 1
- CI Deploy Pipeline (GitHub Actions) Document Required