Merge pull request #64 from spectrocloud/update-pe-version-v4.5.9-118… #116
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: build | |
on: | |
push: | |
branches: | |
- main | |
pull_request: | |
permissions: | |
contents: write | |
concurrency: | |
group: ${{ github.workflow }}-${{ github.ref }} | |
cancel-in-progress: true | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v4 | |
- name: Set up QEMU | |
uses: docker/setup-qemu-action@master | |
with: | |
platforms: all | |
- name: Set up Docker Buildx | |
id: buildx | |
uses: docker/setup-buildx-action@master | |
- name: Install earthly | |
uses: earthly/actions-setup@v1 | |
with: | |
github-token: ${{ secrets.GITHUB_TOKEN }} | |
version: "latest" | |
use-cache: true | |
- name: Calculate Version | |
id: version | |
run: | | |
echo $(git describe --exact-match --tags || echo "v0.0.0-$(git rev-parse --short=8 HEAD)") > VERSION | |
echo "version=$(head -n 1 VERSION)" >> $GITHUB_OUTPUT | |
- name: Build artifacts | |
env: | |
VERSION: ${{ steps.version.outputs.version }} | |
run: | | |
earthly --ci --output +release |