This repository has been archived on 2026-05-19. You can view files and clone it. You cannot open issues or pull requests or push a commit.
Files
de-socket-espace-room-server/.gitea/workflows/build.yml
KeshavAnandCode e802c757f7
Some checks failed
build-service / compile-binaries (push) Failing after 1m1s
added workflow change
2026-05-14 19:36:12 -05:00

65 lines
1.5 KiB
YAML

name: build-service
permissions:
contents: write
on:
push:
branches:
- main
tags:
- "v*"
jobs:
compile-binaries:
runs-on: ubuntu-latest
steps:
- name: checkout
uses: actions/checkout@v4
- name: install-rust
uses: dtolnay/rust-toolchain@stable
with:
targets: aarch64-unknown-linux-gnu,x86_64-unknown-linux-gnu
- name: build-x86
run: cargo build --release --target x86_64-unknown-linux-gnu
- name: build-arm64
env:
CARGO_TARGET_AARCH64_UNKNOWN_LINUX_GNU_LINKER: aarch64-linux-gnu-gcc
run: cargo build --release --target aarch64-unknown-linux-gnu
- name: prepare-release-files
run: |
mkdir -p dist
cp target/x86_64-unknown-linux-gnu/release/escape_room_server \
dist/escape_room_server-linux-x86_64
cp target/aarch64-unknown-linux-gnu/release/escape_room_server \
dist/escape_room_server-linux-arm64
chmod +x dist/*
cd dist
zip escape_room_server-linux-x86_64.zip \
escape_room_server-linux-x86_64
zip escape_room_server-linux-arm64.zip \
escape_room_server-linux-arm64
- name: upload-artifacts
uses: actions/upload-artifact@v4
with:
name: escape-room-binaries
path: dist/*.zip
- name: create-release
if: startsWith(gitea.ref, 'refs/tags/v')
uses: softprops/action-gh-release@v2
with:
files: dist/*.zip