Skip to content

Commit

Permalink
CI debugging
Browse files Browse the repository at this point in the history
  • Loading branch information
plvines committed Dec 20, 2024
1 parent 9bf87f6 commit 6785795
Showing 1 changed file with 136 additions and 136 deletions.
272 changes: 136 additions & 136 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,155 +12,155 @@ permissions:
packages: write

jobs:
builder-image:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v3

- name: Log in to Container Registry
if: github.event_name != 'pull_request'
uses: docker/login-action@v2
with:
registry: ghcr.io
username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }}

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

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

- name: Extract Docker Metadata
id: meta
uses: docker/metadata-action@v4
with:
images: ghcr.io/${{ github.repository }}/raceboat-builder
tags: |
type=ref,event=branch
type=ref,event=pr
type=semver,pattern={{raw}}
type=semver,pattern=v{{major}}.{{minor}}
type=semver,pattern=v{{major}}
- name: Configure Docker Caching
id: cache
uses: int128/docker-build-cache-config-action@v1
with:
image: ghcr.io/${{ github.repository }}/raceboat-builder/cache

- name: Build and Push raceboat-builder Docker Image
uses: docker/build-push-action@v4
with:
context: raceboat-builder-image
file: raceboat-builder-image/Dockerfile
platforms: linux/amd64,linux/arm64
push: ${{ github.event_name != 'pull_request' }}
tags: ${{ steps.meta.outputs.tags }}
labels: ${{ steps.meta.outputs.labels }}
cache-from: ${{ steps.cache.outputs.cache-from }}
cache-to: ${{ steps.cache.outputs.cache-to }}
# builder-image:
# runs-on: ubuntu-latest
# steps:
# - name: Checkout
# uses: actions/checkout@v3

build-framework:
needs: [builder-image]
runs-on: ubuntu-latest
container:
image: ghcr.io/tst-race/raceboat/raceboat-builder:${{ github.head_ref || github.ref_name }}
steps:
- name: Checkout
uses: actions/checkout@v3
# - name: Log in to Container Registry
# if: github.event_name != 'pull_request'
# uses: docker/login-action@v2
# with:
# registry: ghcr.io
# username: ${{ github.actor }}
# password: ${{ secrets.GITHUB_TOKEN }}

# - name: Set up QEMU
# uses: docker/setup-qemu-action@v2
# with:
# platforms: 'arm64,arm'

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

# - name: Extract Docker Metadata
# id: meta
# uses: docker/metadata-action@v4
# with:
# images: ghcr.io/${{ github.repository }}/raceboat-builder
# tags: |
# type=ref,event=branch
# type=ref,event=pr
# type=semver,pattern={{raw}}
# type=semver,pattern=v{{major}}.{{minor}}
# type=semver,pattern=v{{major}}

# - name: Configure Docker Caching
# id: cache
# uses: int128/docker-build-cache-config-action@v1
# with:
# image: ghcr.io/${{ github.repository }}/raceboat-builder/cache

# - name: Build and Push raceboat-builder Docker Image
# uses: docker/build-push-action@v4
# with:
# context: raceboat-builder-image
# file: raceboat-builder-image/Dockerfile
# platforms: linux/amd64,linux/arm64
# push: ${{ github.event_name != 'pull_request' }}
# tags: ${{ steps.meta.outputs.tags }}
# labels: ${{ steps.meta.outputs.labels }}
# cache-from: ${{ steps.cache.outputs.cache-from }}
# cache-to: ${{ steps.cache.outputs.cache-to }}

# build-framework:
# needs: [builder-image]
# runs-on: ubuntu-latest
# container:
# image: ghcr.io/tst-race/raceboat/raceboat-builder:${{ github.head_ref || github.ref_name }}
# steps:
# - name: Checkout
# uses: actions/checkout@v3

- name: Build
run: ./build.sh
# - name: Build
# run: ./build.sh

- name: Create Build Artifact
run: "tar cvf ${{ github.event.repository.name }}.tar.gz -C /__w/raceboat/raceboat/ ./racesdk"
# - name: Create Build Artifact
# run: "tar cvf ${{ github.event.repository.name }}.tar.gz -C /__w/raceboat/raceboat/ ./racesdk"

- name: Upload Build Artifact
uses: actions/upload-artifact@v3
with:
name: "${{ github.event.repository.name }}.tar.gz"
path: "${{ github.event.repository.name }}.tar.gz"
retention-days: 10
# - name: Upload Build Artifact
# uses: actions/upload-artifact@v3
# with:
# name: "${{ github.event.repository.name }}.tar.gz"
# path: "${{ github.event.repository.name }}.tar.gz"
# retention-days: 10

compile-image:
needs: [build-framework]
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v3
# compile-image:
# needs: [build-framework]
# runs-on: ubuntu-latest
# steps:
# - name: Checkout
# uses: actions/checkout@v3

- name: Download Framework Artifacts
uses: actions/download-artifact@v3
with:
name: "${{ github.event.repository.name }}.tar.gz"
# - name: Download Framework Artifacts
# uses: actions/download-artifact@v3
# with:
# name: "${{ github.event.repository.name }}.tar.gz"

- name: debug ls
run: ls -R .
# - name: debug ls
# run: ls -R .

- name: untar
run: tar xf ${{ github.event.repository.name }}.tar.gz
# - name: untar
# run: tar xf ${{ github.event.repository.name }}.tar.gz

- name: debug ls
run: ls -R racesdk
# - name: debug ls
# run: ls -R racesdk

- name: debu pwdg
run: pwd
# - name: debu pwdg
# run: pwd

- name: env
run: env
# - name: env
# run: env

- name: Log in to Container Registry
if: github.event_name != 'pull_request'
uses: docker/login-action@v2
with:
registry: ghcr.io
username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }}

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

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

- name: Extract Docker Metadata
id: meta
uses: docker/metadata-action@v4
with:
images: ghcr.io/${{ github.repository }}/raceboat-compile
tags: |
type=ref,event=branch
type=ref,event=pr
type=semver,pattern={{raw}}
type=semver,pattern=v{{major}}.{{minor}}
type=semver,pattern=v{{major}}
- name: Configure Docker Caching
id: cache
uses: int128/docker-build-cache-config-action@v1
with:
image: ghcr.io/${{ github.repository }}/raceboat-compile/cache

- name: Build and Push raceboat-compile Docker Image
uses: docker/build-push-action@v4
with:
context: /home/runner/work/raceboat/raceboat
file: raceboat-compile-image/Dockerfile
platforms: linux/amd64
push: ${{ github.event_name != 'pull_request' }}
tags: ${{ steps.meta.outputs.tags }}
labels: ${{ steps.meta.outputs.labels }}
cache-from: ${{ steps.cache.outputs.cache-from }}
cache-to: ${{ steps.cache.outputs.cache-to }}
# - name: Log in to Container Registry
# if: github.event_name != 'pull_request'
# uses: docker/login-action@v2
# with:
# registry: ghcr.io
# username: ${{ github.actor }}
# password: ${{ secrets.GITHUB_TOKEN }}

# - name: Set up QEMU
# uses: docker/setup-qemu-action@v2
# with:
# platforms: 'arm64,arm'

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

# - name: Extract Docker Metadata
# id: meta
# uses: docker/metadata-action@v4
# with:
# images: ghcr.io/${{ github.repository }}/raceboat-compile
# tags: |
# type=ref,event=branch
# type=ref,event=pr
# type=semver,pattern={{raw}}
# type=semver,pattern=v{{major}}.{{minor}}
# type=semver,pattern=v{{major}}

# - name: Configure Docker Caching
# id: cache
# uses: int128/docker-build-cache-config-action@v1
# with:
# image: ghcr.io/${{ github.repository }}/raceboat-compile/cache

# - name: Build and Push raceboat-compile Docker Image
# uses: docker/build-push-action@v4
# with:
# context: /home/runner/work/raceboat/raceboat
# file: raceboat-compile-image/Dockerfile
# platforms: linux/amd64
# push: ${{ github.event_name != 'pull_request' }}
# tags: ${{ steps.meta.outputs.tags }}
# labels: ${{ steps.meta.outputs.labels }}
# cache-from: ${{ steps.cache.outputs.cache-from }}
# cache-to: ${{ steps.cache.outputs.cache-to }}

runtime-image:
needs: [compile-image]
# needs: [compile-image]
runs-on: ubuntu-latest
steps:
- name: Checkout
Expand Down Expand Up @@ -231,7 +231,7 @@ jobs:
labels: ${{ steps.meta.outputs.labels }}
cache-from: ${{ steps.cache.outputs.cache-from }}
cache-to: ${{ steps.cache.outputs.cache-to }}
build-contexts: ghcr.io/tst-race/raceboat/raceboat-compile:latest=ghcr.io/tst-race/raceboat/raceboat-compile:${{ steps.meta.outputs.version }}
build-contexts: ghcr.io/tst-race/raceboat/raceboat-compile=docker-image://ghcr.io/tst-race/raceboat/raceboat-compile:${{ steps.meta.outputs.version }}



Expand Down

0 comments on commit 6785795

Please sign in to comment.