add lotus 1.29 #52
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' | |
tags: | |
- 'v*' | |
pull_request: | |
jobs: | |
build: | |
name: Containers | |
runs-on: ubuntu-latest | |
permissions: | |
contents: read | |
packages: write | |
strategy: | |
fail-fast: false | |
matrix: | |
version: | |
- v1.23.1 | |
- v1.23.2 | |
- v1.23.3 | |
- v1.23.4-rc1 | |
- v1.23.4-rc2 | |
- v1.24.0-rc1 | |
- v1.25.0-rc1 | |
- v1.24.0 | |
- v1.25.0 | |
- v1.25.1 | |
- v1.25.2 | |
- v1.26.0-rc1 | |
- v1.26.0 | |
- v1.26.1 | |
- v1.26.2 | |
- v1.26.3 | |
- v1.27.0 | |
- v1.27.1 | |
- v1.27.2 | |
- v1.28.0 | |
- v1.28.1 | |
- v1.28.2 | |
- v1.29.0 | |
- v1.29.1 | |
net: | |
- name: mainnet | |
goflags: '' | |
- name: devnet | |
goflags: '-tags=debug' | |
platform: | |
- linux/amd64,linux/arm64 | |
steps: | |
- name: Log in to the Container registry | |
uses: docker/login-action@v2 | |
with: | |
registry: ghcr.io | |
username: ${{ github.actor }} | |
password: ${{ secrets.GITHUB_TOKEN }} | |
- name: Extract metadata for Lotus ${{ matrix.version }} ${{ matrix.net.name }} | |
id: meta | |
uses: docker/metadata-action@v4 | |
with: | |
images: ghcr.io/${{ github.repository }} | |
tags: | | |
type=raw,value=lotus-${{ matrix.version }}-${{ matrix.net.name }} | |
- name: Check if image exists | |
id: checker | |
run: | | |
if ! docker manifest inspect ${{ steps.meta.outputs.tags }} | |
then | |
echo "IMAGE_EXISTS=false" >> $GITHUB_ENV | |
fi | |
- name: Free Disk Space (Ubuntu) | |
uses: jlumbroso/free-disk-space@main | |
if: env.IMAGE_EXISTS == 'false' | |
with: | |
tool-cache: false | |
android: true | |
dotnet: true | |
haskell: true | |
- name: Checkout | |
uses: actions/checkout@v3 | |
if: env.IMAGE_EXISTS == 'false' | |
with: | |
repository: filecoin-project/lotus | |
ref: ${{ matrix.version }} | |
path: lotus | |
- name: Set up QEMU | |
uses: docker/setup-qemu-action@v2 | |
if: env.IMAGE_EXISTS == 'false' | |
- name: Set up Docker Buildx | |
uses: docker/setup-buildx-action@v2 | |
if: env.IMAGE_EXISTS == 'false' | |
with: | |
platforms: ${{ matrix.platform }} | |
- name: Build Lotus ${{ matrix.version }} ${{ matrix.net.name }} | |
uses: docker/build-push-action@v4 | |
if: env.IMAGE_EXISTS == 'false' | |
env: | |
REGISTRY_CACHE_REF: ghcr.io/${{ github.repository }}:cache | |
with: | |
context: lotus | |
cache-from: type=registry,ref=${{ env.REGISTRY_CACHE_REF }} | |
cache-to: type=registry,mode=max,ref=${{ env.REGISTRY_CACHE_REF }} | |
push: ${{ github.event_name != 'pull_request' }} | |
tags: ${{ steps.meta.outputs.tags }} | |
labels: ${{ steps.meta.outputs.labels }} | |
platforms: ${{ matrix.platform }} | |
build-args: | | |
GOFLAGS=${{ matrix.net.goflags }} |