Skip to content

chore(hello-tracing-gateway): release version 1.3.1 #13

chore(hello-tracing-gateway): release version 1.3.1

chore(hello-tracing-gateway): release version 1.3.1 #13

Workflow file for this run

name: release-hello-tracing-backend
on:
push:
tags:
- hello-tracing-backend/v*
concurrency:
group: ${{ github.workflow }}-${{ github.head_ref || github.run_id }}
cancel-in-progress: true
jobs:
check:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Install Rust
uses: dtolnay/rust-toolchain@stable
- name: Install just
uses: taiki-e/install-action@v2
with:
tool: just
- name: Install protoc
uses: arduino/setup-protoc@v3
with:
repo-token: ${{ secrets.GITHUB_TOKEN }}
- uses: Swatinem/rust-cache@v2
- name: just check
run: just check
fmt-check:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Install Rust (nightly for fmt)
uses: dtolnay/rust-toolchain@nightly
with:
components: rustfmt
- name: Install just
uses: taiki-e/install-action@v2
with:
tool: just
- uses: Swatinem/rust-cache@v2
- name: just fmt-check
run: just fmt-check
lint:
runs-on: ubuntu-latest
needs: [check, fmt-check]
steps:
- uses: actions/checkout@v4
- name: Install Rust
uses: dtolnay/rust-toolchain@stable
with:
components: clippy
- name: Install just
uses: taiki-e/install-action@v2
with:
tool: just
- name: Install protoc
uses: arduino/setup-protoc@v3
with:
repo-token: ${{ secrets.GITHUB_TOKEN }}
- uses: Swatinem/rust-cache@v2
- name: just lint
run: just lint
test:
runs-on: ubuntu-latest
needs: [check, fmt-check]
steps:
- uses: actions/checkout@v4
- name: Install Rust
uses: dtolnay/rust-toolchain@stable
- name: Install just
uses: taiki-e/install-action@v2
with:
tool: just
- name: Install protoc
uses: arduino/setup-protoc@v3
with:
repo-token: ${{ secrets.GITHUB_TOKEN }}
- uses: Swatinem/rust-cache@v2
- name: just test
run: just test
release:
runs-on: ubuntu-latest
needs: [lint, test]
steps:
- name: Login to DockerHub
uses: docker/login-action@v3
with:
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_TOKEN }}
- name: Prepare metadata (tags, labels) for Docker
id: meta
uses: docker/metadata-action@v5
with:
images: hseeberger/hello-tracing-backend
tags: |
type=match,pattern=hello-tracing-backend/v(\d.\d.\d),group=1
type=sha,prefix=,suffix=,format=long
type=raw,value=latest,enable={{is_default_branch}}
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v3
- name: Docker build and push hello-tracing-backend
uses: docker/build-push-action@v6
with:
file: hello-tracing-backend/Dockerfile
platforms: linux/amd64,linux/arm64
tags: ${{ steps.meta.outputs.tags }}
labels: ${{ steps.meta.outputs.labels }}
push: true