添加 Drone 构建
Some checks reported errors
continuous-integration/drone/push Build encountered an error
Some checks reported errors
continuous-integration/drone/push Build encountered an error
This commit is contained in:
35
.drone.yml
Normal file
35
.drone.yml
Normal file
@ -0,0 +1,35 @@
|
||||
kind: pipeline
|
||||
type: docker
|
||||
name: rust-build-amd64
|
||||
|
||||
steps:
|
||||
- name: check-version
|
||||
image: rust:1.93
|
||||
commands:
|
||||
- rustc --version
|
||||
- cargo --version
|
||||
|
||||
- name: build
|
||||
image: rust:1.93
|
||||
environment:
|
||||
CARGO_HOME: .cargo
|
||||
commands:
|
||||
- cargo build --release --target x86_64-unknown-linux-gnu
|
||||
|
||||
- name: test
|
||||
image: rust:1.93
|
||||
commands:
|
||||
- cargo test --release
|
||||
|
||||
- name: copy-out
|
||||
image: busybox
|
||||
volumes:
|
||||
- name: artifacts
|
||||
path: /artifacts
|
||||
commands:
|
||||
- cp target/release/my-rust-app /artifacts/my-rust-app-amd64
|
||||
|
||||
volumes:
|
||||
- name: artifacts
|
||||
host:
|
||||
path: /opt/build_artifacts
|
||||
Reference in New Issue
Block a user