Skip to content

Commit

Permalink
bump versions and add caching
Browse files Browse the repository at this point in the history
  • Loading branch information
cnolanminich committed Jun 12, 2024
1 parent 09f5a45 commit 2ce13f1
Showing 1 changed file with 18 additions and 4 deletions.
22 changes: 18 additions & 4 deletions .github/workflows/deploy-dagster-cloud.yml
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ jobs:
uses: dagster-io/dagster-cloud-action/actions/utils/[email protected]

- name: Checkout
uses: actions/checkout@v3
uses: actions/checkout@v4
if: steps.prerun.outputs.result != 'skip'
with:
ref: ${{ github.head_ref }}
Expand All @@ -54,8 +54,11 @@ jobs:
if: steps.prerun.outputs.result != 'skip'
run: echo "IMAGE_TAG=$GITHUB_SHA-$GITHUB_RUN_ID-$GITHUB_RUN_ATTEMPT" >> $GITHUB_ENV && echo $IMAGE_TAG

- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v3

- name: Configure AWS credentials
uses: aws-actions/configure-aws-credentials@v2
uses: aws-actions/configure-aws-credentials@v4
if: steps.prerun.outputs.result != 'skip'
with:
aws-access-key-id: ${{ secrets.AWS_ACCESS_KEY_ID }}
Expand All @@ -64,7 +67,8 @@ jobs:

- name: Login to ECR
if: ${{ steps.prerun.outputs.result != 'skip' }}
uses: aws-actions/amazon-ecr-login@v1
uses: aws-actions/amazon-ecr-login@v2
with: mask-password: 'true'

- name: Set Branch Deployment Environment Variable for PR
if: steps.prerun.outputs.result != 'skip' && github.event_name == 'pull_request'
Expand All @@ -85,11 +89,13 @@ jobs:
- name: Build and upload Docker image for data-eng-pipeline
if: steps.prerun.outputs.result != 'skip'
uses: docker/build-push-action@v4
uses: docker/build-push-action@v5
with:
context: .
push: true
tags: ${{ env.IMAGE_REGISTRY }}:${{ env.IMAGE_TAG }}-data-eng-pipeline
cache-from: type=gha
cache-to: type=gha,mode=max

- name: Update build session with image tag for data-eng-pipeline
id: ci-set-build-output-data-eng-pipeline
Expand All @@ -106,6 +112,8 @@ jobs:
context: ./hooli_basics
push: true
tags: ${{ env.IMAGE_REGISTRY }}:${{ env.IMAGE_TAG }}-basics
cache-from: type=gha
cache-to: type=gha,mode=max

- name: Update build session with image tag for basics
id: ci-set-build-output-basics
Expand Down Expand Up @@ -138,6 +146,8 @@ jobs:
context: ./hooli_snowflake_insights
push: true
tags: ${{ env.IMAGE_REGISTRY }}:${{ env.IMAGE_TAG }}-snowflake-insights
cache-from: type=gha
cache-to: type=gha,mode=max

- name: Update build session with image tag for snowflake insights
id: ci-set-build-output-snowflake-insights
Expand All @@ -154,6 +164,8 @@ jobs:
context: ./hooli-demo-assets
push: true
tags: ${{ env.IMAGE_REGISTRY }}:${{ env.IMAGE_TAG }}-demo-assets
cache-from: type=gha
cache-to: type=gha,mode=max

- name: Update build session with image tag for demo_assets
id: ci-set-build-output-demo-assets
Expand All @@ -170,6 +182,8 @@ jobs:
context: ./hooli_data_eng/utils/example_container
push: true
tags: ${{ env.IMAGE_REGISTRY }}:latest-pipes-example
cache-from: type=gha
cache-to: type=gha,mode=max

# Deploy
- name: Deploy to Dagster Cloud
Expand Down

0 comments on commit 2ce13f1

Please sign in to comment.