Skip to content

Commit

Permalink
Merge pull request #371 from anoma/update-ci
Browse files Browse the repository at this point in the history
Update CI
  • Loading branch information
Fraccaman authored Aug 6, 2024
2 parents 22d73a4 + 6fd4cf3 commit b4d5a95
Showing 1 changed file with 11 additions and 28 deletions.
39 changes: 11 additions & 28 deletions .github/workflows/build-docs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,6 @@ name: Build docker images

on:
workflow_dispatch:
inputs:
tag:
description: 'The docker image tag'
required: true
push:
branches:
- master
Expand All @@ -18,10 +14,13 @@ jobs:
docker:
runs-on: [ubuntu-22.04]
needs: [checks]
env:
GIT_LFS_SKIP_SMUDGE: 1
REGISTRY_URL: ghcr.io
strategy:
fail-fast: false
matrix:
make:
docker:
- name: Build Specs image
image: specs
path: specs
Expand All @@ -39,44 +38,28 @@ jobs:
uses: docker/setup-qemu-action@v3
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v3
with:
version: v0.9.1
- name: Login to private registry
- name: Login to GHCR
uses: docker/login-action@v3
with:
registry: ${{ secrets.REGISTRY_URL }}
username: ${{ secrets.REGISTRY_USERNAME }}
password: ${{ secrets.REGISTRY_PASSWORD }}
- name: Docker meta
id: meta
uses: docker/metadata-action@v4
with:
images: ${{ secrets.REGISTRY_URL }}/namada-${{ matrix.make.image }}-docs
tags: |
type=schedule
type=ref,event=branch
type=ref,event=pr
type=semver,pattern={{version}}
type=semver,pattern={{major}}.{{minor}}
type=semver,pattern={{major}}
type=raw,value=latest
- name: ${{ matrix.make.name }}
registry: ${{ env.REGISTRY_URL }}
username: ${{ github.repository_owner }}
password: ${{ secrets.GITHUB_TOKEN }}
- name: ${{ matrix.docker.name }}
uses: docker/build-push-action@v6
with:
context: .
file: Dockerfile
push: ${{ github.ref == 'refs/heads/master' }}
tags: ${{ steps.meta.outputs.tags }}
tags: ${{ env.REGISTRY_URL }}/anoma/namada-docs:${{ matrix.docker.image }}-main
labels: ${{ steps.meta.outputs.labels }}
build-args: |
"TARGET=${{ matrix.make.path }}"
"TARGET=${{ matrix.docker.path }}"
checks:
runs-on: [ubuntu-22.04]
strategy:
fail-fast: false
matrix:
lychee_version: [lycheeverse/[email protected]]
make:
- name: docs
path: docs
Expand Down

0 comments on commit b4d5a95

Please sign in to comment.