kind: pipeline type: docker name: clippy platform: arch: amd64 clone: disable: true steps: - name: clone image: alpine/git:latest user: root commands: - git clone $DRONE_GIT_HTTP_URL . - git checkout $DRONE_COMMIT - chown -R 991:991 . - name: clippy image: asonix/rust-builder:latest-linux-amd64 pull: always commands: - rustup component add clippy - cargo clippy -- -D warnings trigger: event: - push - pull_request - tag --- kind: pipeline type: docker name: tests platform: arch: amd64 clone: disable: true steps: - name: clone image: alpine/git:latest user: root commands: - git clone $DRONE_GIT_HTTP_URL . - git checkout $DRONE_COMMIT - chown -R 991:991 . - name: tests image: asonix/rust-builder:latest-linux-amd64 pull: always commands: - cargo test trigger: event: - push - pull_request - tag --- kind: pipeline type: docker name: check-amd64 platform: arch: amd64 clone: disable: true steps: - name: clone image: alpine/git:latest user: root commands: - git clone $DRONE_GIT_HTTP_URL . - git checkout $DRONE_COMMIT - chown -R 991:991 . - name: check image: asonix/rust-builder:latest-linux-amd64 pull: always commands: - cargo check --target=$TARGET trigger: event: - push - pull_request --- kind: pipeline type: docker name: build-amd64 platform: arch: amd64 clone: disable: true steps: - name: clone image: alpine/git:latest user: root commands: - git clone $DRONE_GIT_HTTP_URL . - git checkout $DRONE_COMMIT - chown -R 991:991 . - name: build image: asonix/rust-builder:latest-linux-amd64 pull: always commands: - cargo build --target=$TARGET --release - $TOOL-strip target/$TARGET/release/router - mv target/$TARGET/release/router router-linux-amd64 - name: publish image: plugins/gitea-release:1 settings: api_key: from_secret: gitea_token base_url: https://git.asonix.dog files: - router-linux-amd64 depends_on: - clippy - tests trigger: event: - tag --- kind: pipeline type: docker name: check-arm64v8 platform: arch: amd64 clone: disable: true steps: - name: clone image: alpine/git:latest user: root commands: - git clone $DRONE_GIT_HTTP_URL . - git checkout $DRONE_COMMIT - chown -R 991:991 . - name: check image: asonix/rust-builder:latest-linux-arm64v8 pull: always commands: - cargo check --target=$TARGET trigger: event: - push - pull_request --- kind: pipeline type: docker name: build-arm64v8 platform: arch: amd64 clone: disable: true steps: - name: clone image: alpine/git:latest user: root commands: - git clone $DRONE_GIT_HTTP_URL . - git checkout $DRONE_COMMIT - chown -R 991:991 . - name: build image: asonix/rust-builder:latest-linux-arm64v8 pull: always commands: - cargo build --target=$TARGET --release - $TOOL-strip target/$TARGET/release/router - mv target/$TARGET/release/router router-linux-arm64v8 - name: publish image: plugins/gitea-release:1 settings: api_key: from_secret: gitea_token base_url: https://git.asonix.dog files: - router-linux-arm64v8 depends_on: - clippy - tests trigger: event: - tag --- kind: pipeline type: docker name: check-arm32v7 platform: arch: amd64 clone: disable: true steps: - name: clone image: alpine/git:latest user: root commands: - git clone $DRONE_GIT_HTTP_URL . - git checkout $DRONE_COMMIT - chown -R 991:991 . - name: check image: asonix/rust-builder:latest-linux-arm32v7 pull: always commands: - cargo check --target=$TARGET trigger: event: - push - pull_request --- kind: pipeline type: docker name: build-arm32v7 platform: arch: amd64 clone: disable: true steps: - name: clone image: alpine/git:latest user: root commands: - git clone $DRONE_GIT_HTTP_URL . - git checkout $DRONE_COMMIT - chown -R 991:991 . - name: build image: asonix/rust-builder:latest-linux-arm32v7 pull: always commands: - cargo build --target=$TARGET --release - $TOOL-strip target/$TARGET/release/router - mv target/$TARGET/release/router router-linux-arm32v7 - name: publish image: plugins/gitea-release:1 settings: api_key: from_secret: gitea_token base_url: https://git.asonix.dog files: - router-linux-arm32v7 depends_on: - clippy - tests trigger: event: - tag