Skip to content

fix(deps): update rust crate tokio to v1.41.1 #101

fix(deps): update rust crate tokio to v1.41.1

fix(deps): update rust crate tokio to v1.41.1 #101

Workflow file for this run

name: Deploy Release
on:
push:
branches:
- 'v[0-9]+.[0-9]+.[0-9]+-rc.[0-9]+'
- '[0-9]+.[0-9]+.[0-9]+-rc.[0-9]+'
tags:
- 'v[0-9]+.[0-9]+.[0-9]+-rc.[0-9]+'
- '[0-9]+.[0-9]+.[0-9]+-rc.[0-9]+'
env:
CI: true
jobs:
build:
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [ ubuntu-latest, macos-latest, windows-latest ]
include:
- os: ubuntu-latest
target: x86_64-unknown-linux-gnu
- os: macos-latest
target: x86_64-apple-darwin
- os: windows-latest
target: x86_64-pc-windows-msvc
steps:
- uses: actions/checkout@v4
- name: Install Rust
uses: dtolnay/rust-toolchain@master
with:
toolchain: stable
target: ${{ matrix.target }}
- name: Install cargo-edit
run: |
cargo install cargo-edit
- name: Update Cargo Version
env:
VERSION: ${{ github.head_ref || github.ref_name }}
run: cargo set-version ${{ env.VERSION }}
- name: Build
run: cargo build --release --target ${{ matrix.target }}
- name: Upload artifact
uses: actions/upload-artifact@v4
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
TAG_NAME: ${{ github.ref }} # Assumes the tag name is the same as the ref. Adjust if necessary.
BRANCH_NAME: ${{ github.head_ref || github.ref_name }}
with:
name: doclytics-${{ env.BRANCH_NAME }}-${{ matrix.os }}
path: |
./target/${{ matrix.target }}/release/doclytics${{ matrix.os == 'windows-latest' && '.exe' || '' }}
build-docker:
runs-on: ubuntu-latest
permissions:
packages: write
contents: read
if: ${{ github.ref }} != 'master' && ${{ github.ref }} != 'development'
env:
BRANCH_NAME: ${{ github.head_ref || github.ref_name }}
steps:
- name: Checkout code
uses: actions/checkout@v4
- name: Set up Docker Build
uses: docker/setup-buildx-action@v3
- name: Login to Docker Registry
uses: docker/login-action@v3
with:
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_TOKEN }}
- name: Build and push
uses: docker/build-push-action@v6
env:
VERSION: ${{ github.head_ref || github.ref_name }}
with:
context: .
push: true
tags: ${{ secrets.DOCKERHUB_USERNAME }}/doclytics:${{ env.BRANCH_NAME }}
platforms: linux/amd64,linux/arm64
- name: 'Login to GitHub Container Registry'
uses: docker/login-action@v3
with:
registry: ghcr.io
username: ${{github.actor}}
password: ${{secrets.GITHUB_TOKEN}}
- name: Build and push to GitHub Container Registry
env:
VERSION: ${{ github.head_ref || github.ref_name }}
uses: docker/build-push-action@v6
with:
context: .
push: true
tags: ghcr.io/b-urb/doclytics:v${{ env.BRANCH_NAME }}
platforms: linux/amd64,linux/arm64