mouse/.drone.yml
Jochen Maes 61f6c2b0bd
All checks were successful
continuous-integration/drone/push Build is passing
removes linker from manifest and adds as env var
Signed-off-by: Jochen Maes <jochen@sejo-it.be>
2023-10-31 06:59:12 +01:00

49 lines
1.3 KiB
YAML

---
kind: pipeline
type: docker
name: mouse-release
platform:
arch: amd64
#trigger:
# event:
# - tag
volumes:
- name: dockersock
host:
path: /var/run/docker.sock
- name: artifacts
temp: {}
steps:
- name: build amd64
image: rust:1.73-alpine
commands:
- apk add --no-cache musl-dev gcc-aarch64-none-elf
- rustup target add x86_64-unknown-linux-musl
- rustup target add aarch64-unknown-linux-musl
- cargo build --target x86_64-unknown-linux-musl --bins -r --config 'package.version="${DRONE_TAG##v}"'
- CARGO_TARGET_AARCH64_UNKNOWN_LINUX_MUSL_LINKER=/usr/bin/aarch64-none-elf-gcc cargo build --target aarch64-unknown-linux-musl --bins -r --config 'package.version="${DRONE_TAG##v}"'
- cp target/x86_64-unknown-linux-musl/release/mouse /artifacts/mouse-amd64
- cp target/aarch64-unknown-linux-musl/release/mouse /artifacts/mouse-arm64
volumes:
- name: artifacts
path: /artifacts/
- name: create gitea release
image: plugins/gitea-release
settings:
api_key:
from_secret: gitea_api_key
base_url: https://gitea.sejo-it.be
checksum: sha256
files: /artifacts/*
volumes:
- name: artifacts
path: /artifacts/
when:
event:
- tag