Skip to content

Merge branch 'main' of https://github.com/ideal-world/bios #157

Merge branch 'main' of https://github.com/ideal-world/bios

Merge branch 'main' of https://github.com/ideal-world/bios #157

name: Publish rust gateways docker image
on:
push:
paths:
- "backend/gateways/spacegate-plugins/**"
- "backend/supports/auth/**"
- "backend/services/spacegate/**"
- "Cargo.toml"
- ".github/workflows/space-gateways-docker-push.yml"
jobs:
push_to_registry:
name: Push docker image to registry
runs-on: ubuntu-latest
permissions:
packages: write
contents: read
steps:
- name: Check out the repo
uses: actions/checkout@v3
- name: Init rust envrionment
uses: actions-rs/toolchain@v1
with:
profile: minimal
toolchain: stable
components: rustfmt, clippy
- name: Cache rust
uses: Swatinem/rust-cache@v2
- name: Build rust
run: cargo build --release -p bios-spacegate
- name: Copy binary to workspace
run: cp ./target/release/bios-spacegate ./backend/services/spacegate/
- name: Build and push Docker image to dockerhub
uses: mr-smithers-excellent/docker-build-push@v5
with:
directory: backend/services/spacegate
dockerfile: backend/services/spacegate/Dockerfile
registry: docker.io
image: ecfront/bios-spacegate
tags: latest
username: ${{ secrets.DOCKER_USERNAME }}
password: ${{ secrets.DOCKER_PASSWORD }}