Skip to content

Commit

Permalink
Merge pull request #12 from spacelift-io/revert-11-publish-arm-images
Browse files Browse the repository at this point in the history
Revert "Publish ARM images to preprod env"
  • Loading branch information
cube2222 authored Dec 9, 2022
2 parents d6808e6 + d17e12f commit e52182c
Show file tree
Hide file tree
Showing 10 changed files with 94 additions and 254 deletions.
82 changes: 0 additions & 82 deletions .github/workflows/build.yml

This file was deleted.

182 changes: 60 additions & 122 deletions .github/workflows/deploy-preproduction.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,19 +18,9 @@ jobs:
runs-on: ubuntu-latest
steps:
- name: Check out repository code
uses: actions/checkout@main

- name: Set up QEMU
uses: docker/setup-qemu-action@v2
with:
platforms: linux/arm64

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

uses: actions/checkout@master
- name: Set env
run: echo "RELEASE_VERSION=${GITHUB_REF#refs/*/}" >> $GITHUB_ENV

- name: Set env
run: echo "PULUMI_VERSION=${RELEASE_VERSION#dev-}" >> $GITHUB_ENV

Expand All @@ -50,33 +40,24 @@ jobs:
env:
REPOSITORY_BASE_PATH: ${{ secrets.PREPROD_REPOSITORY_BASE_PATH }}

- name: Build and push the image
uses: docker/build-push-action@v3
with:
push: true
platforms: linux/amd64,linux/arm64
context: base-alpine
build-args: PULUMI_VERSION=${PULUMI_VERSION}
tags: ${{ secrets.PREPROD_REPOSITORY_BASE_PATH }}/runner-pulumi-base-alpine:${RELEASE_VERSION}
- name: Build the image
run: cd base-alpine && docker build --build-arg PULUMI_VERSION=${PULUMI_VERSION} --tag ${REPOSITORY_BASE_PATH}/runner-pulumi-base-alpine:${RELEASE_VERSION} .
env:
REPOSITORY_BASE_PATH: ${{ secrets.PREPROD_REPOSITORY_BASE_PATH }}

- name: Push the image to ECR
run: docker push ${REPOSITORY_BASE_PATH}/runner-pulumi-base-alpine:${RELEASE_VERSION}
env:
REPOSITORY_BASE_PATH: ${{ secrets.PREPROD_REPOSITORY_BASE_PATH }}

base-debian:
name: Build and deploy the base Debian image
runs-on: ubuntu-latest
steps:
- name: Check out repository code
uses: actions/checkout@main

- name: Set up QEMU
uses: docker/setup-qemu-action@v2
with:
platforms: linux/arm64

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

uses: actions/checkout@master
- name: Set env
run: echo "RELEASE_VERSION=${GITHUB_REF#refs/*/}" >> $GITHUB_ENV

- name: Set env
run: echo "PULUMI_VERSION=${RELEASE_VERSION#dev-}" >> $GITHUB_ENV

Expand All @@ -96,14 +77,15 @@ jobs:
env:
REPOSITORY_BASE_PATH: ${{ secrets.PREPROD_REPOSITORY_BASE_PATH }}

- name: Build and push the image
uses: docker/build-push-action@v3
with:
push: true
platforms: linux/amd64,linux/arm64
context: base-debian
build-args: PULUMI_VERSION=${PULUMI_VERSION}
tags: ${{ secrets.PREPROD_REPOSITORY_BASE_PATH }}/runner-pulumi-base-debian:${RELEASE_VERSION}
- name: Build the image
run: cd base-debian && docker build --build-arg PULUMI_VERSION=${PULUMI_VERSION} --tag ${REPOSITORY_BASE_PATH}/runner-pulumi-base-debian:${RELEASE_VERSION} .
env:
REPOSITORY_BASE_PATH: ${{ secrets.PREPROD_REPOSITORY_BASE_PATH }}

- name: Push the image to ECR
run: docker push ${REPOSITORY_BASE_PATH}/runner-pulumi-base-debian:${RELEASE_VERSION}
env:
REPOSITORY_BASE_PATH: ${{ secrets.PREPROD_REPOSITORY_BASE_PATH }}

javascript:
needs:
Expand All @@ -112,19 +94,9 @@ jobs:
runs-on: ubuntu-latest
steps:
- name: Check out repository code
uses: actions/checkout@main

- name: Set up QEMU
uses: docker/setup-qemu-action@v2
with:
platforms: linux/arm64

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

uses: actions/checkout@master
- name: Set env
run: echo "RELEASE_VERSION=${GITHUB_REF#refs/*/}" >> $GITHUB_ENV

- name: Set env
run: echo "PULUMI_VERSION=${RELEASE_VERSION#dev-}" >> $GITHUB_ENV

Expand All @@ -144,16 +116,15 @@ jobs:
env:
REPOSITORY_BASE_PATH: ${{ secrets.PREPROD_REPOSITORY_BASE_PATH }}

- name: Build and push the image
uses: docker/build-push-action@v3
with:
push: true
platforms: linux/amd64,linux/arm64
context: javascript
build-args: |
REPOSITORY_BASE_PATH=${REPOSITORY_BASE_PATH}
RELEASE_VERSION=${RELEASE_VERSION}
tags: ${{ secrets.PREPROD_REPOSITORY_BASE_PATH }}/runner-pulumi-javascript:${RELEASE_VERSION}
- name: Build the image
run: cd javascript && docker build --build-arg REPOSITORY_BASE_PATH=${REPOSITORY_BASE_PATH} --build-arg RELEASE_VERSION=${RELEASE_VERSION} --tag ${REPOSITORY_BASE_PATH}/runner-pulumi-javascript:${RELEASE_VERSION} .
env:
REPOSITORY_BASE_PATH: ${{ secrets.PREPROD_REPOSITORY_BASE_PATH }}

- name: Push the image to ECR
run: docker push ${REPOSITORY_BASE_PATH}/runner-pulumi-javascript:${RELEASE_VERSION}
env:
REPOSITORY_BASE_PATH: ${{ secrets.PREPROD_REPOSITORY_BASE_PATH }}

golang:
needs:
Expand All @@ -162,19 +133,9 @@ jobs:
runs-on: ubuntu-latest
steps:
- name: Check out repository code
uses: actions/checkout@main

- name: Set up QEMU
uses: docker/setup-qemu-action@v2
with:
platforms: linux/arm64

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

uses: actions/checkout@master
- name: Set env
run: echo "RELEASE_VERSION=${GITHUB_REF#refs/*/}" >> $GITHUB_ENV

- name: Set env
run: echo "PULUMI_VERSION=${RELEASE_VERSION#dev-}" >> $GITHUB_ENV

Expand All @@ -194,16 +155,15 @@ jobs:
env:
REPOSITORY_BASE_PATH: ${{ secrets.PREPROD_REPOSITORY_BASE_PATH }}

- name: Build and push the image
uses: docker/build-push-action@v3
with:
push: true
platforms: linux/amd64,linux/arm64
context: golang
build-args: |
REPOSITORY_BASE_PATH=${REPOSITORY_BASE_PATH}
RELEASE_VERSION=${RELEASE_VERSION}
tags: ${{ secrets.PREPROD_REPOSITORY_BASE_PATH }}/runner-pulumi-golang:${RELEASE_VERSION}
- name: Build the image
run: cd golang && docker build --build-arg REPOSITORY_BASE_PATH=${REPOSITORY_BASE_PATH} --build-arg RELEASE_VERSION=${RELEASE_VERSION} --tag ${REPOSITORY_BASE_PATH}/runner-pulumi-golang:${RELEASE_VERSION} .
env:
REPOSITORY_BASE_PATH: ${{ secrets.PREPROD_REPOSITORY_BASE_PATH }}

- name: Push the image to ECR
run: docker push ${REPOSITORY_BASE_PATH}/runner-pulumi-golang:${RELEASE_VERSION}
env:
REPOSITORY_BASE_PATH: ${{ secrets.PREPROD_REPOSITORY_BASE_PATH }}

python:
needs:
Expand All @@ -212,19 +172,9 @@ jobs:
runs-on: ubuntu-latest
steps:
- name: Check out repository code
uses: actions/checkout@main

- name: Set up QEMU
uses: docker/setup-qemu-action@v2
with:
platforms: linux/arm64

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

uses: actions/checkout@master
- name: Set env
run: echo "RELEASE_VERSION=${GITHUB_REF#refs/*/}" >> $GITHUB_ENV

- name: Set env
run: echo "PULUMI_VERSION=${RELEASE_VERSION#dev-}" >> $GITHUB_ENV

Expand All @@ -244,16 +194,15 @@ jobs:
env:
REPOSITORY_BASE_PATH: ${{ secrets.PREPROD_REPOSITORY_BASE_PATH }}

- name: Build and push the image
uses: docker/build-push-action@v3
with:
push: true
platforms: linux/amd64,linux/arm64
context: python
build-args: |
REPOSITORY_BASE_PATH=${REPOSITORY_BASE_PATH}
RELEASE_VERSION=${RELEASE_VERSION}
tags: ${{ secrets.PREPROD_REPOSITORY_BASE_PATH }}/runner-pulumi-python:${RELEASE_VERSION}
- name: Build the image
run: cd python && docker build --build-arg REPOSITORY_BASE_PATH=${REPOSITORY_BASE_PATH} --build-arg RELEASE_VERSION=${RELEASE_VERSION} --tag ${REPOSITORY_BASE_PATH}/runner-pulumi-python:${RELEASE_VERSION} .
env:
REPOSITORY_BASE_PATH: ${{ secrets.PREPROD_REPOSITORY_BASE_PATH }}

- name: Push the image to ECR
run: docker push ${REPOSITORY_BASE_PATH}/runner-pulumi-python:${RELEASE_VERSION}
env:
REPOSITORY_BASE_PATH: ${{ secrets.PREPROD_REPOSITORY_BASE_PATH }}

dotnet:
needs:
Expand All @@ -262,19 +211,9 @@ jobs:
runs-on: ubuntu-latest
steps:
- name: Check out repository code
uses: actions/checkout@main

- name: Set up QEMU
uses: docker/setup-qemu-action@v2
with:
platforms: linux/arm64

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

uses: actions/checkout@master
- name: Set env
run: echo "RELEASE_VERSION=${GITHUB_REF#refs/*/}" >> $GITHUB_ENV

- name: Set env
run: echo "PULUMI_VERSION=${RELEASE_VERSION#dev-}" >> $GITHUB_ENV

Expand All @@ -294,13 +233,12 @@ jobs:
env:
REPOSITORY_BASE_PATH: ${{ secrets.PREPROD_REPOSITORY_BASE_PATH }}

- name: Build and push the image
uses: docker/build-push-action@v3
with:
push: true
platforms: linux/amd64,linux/arm64
context: dotnet
build-args: |
REPOSITORY_BASE_PATH=${REPOSITORY_BASE_PATH}
RELEASE_VERSION=${RELEASE_VERSION}
tags: ${{ secrets.PREPROD_REPOSITORY_BASE_PATH }}/runner-pulumi-dotnet:${RELEASE_VERSION}
- name: Build the image
run: cd dotnet && docker build --build-arg REPOSITORY_BASE_PATH=${REPOSITORY_BASE_PATH} --build-arg RELEASE_VERSION=${RELEASE_VERSION} --tag ${REPOSITORY_BASE_PATH}/runner-pulumi-dotnet:${RELEASE_VERSION} .
env:
REPOSITORY_BASE_PATH: ${{ secrets.PREPROD_REPOSITORY_BASE_PATH }}

- name: Push the image to ECR
run: docker push ${REPOSITORY_BASE_PATH}/runner-pulumi-dotnet:${RELEASE_VERSION}
env:
REPOSITORY_BASE_PATH: ${{ secrets.PREPROD_REPOSITORY_BASE_PATH }}
Loading

0 comments on commit e52182c

Please sign in to comment.