CI/CD #1

Merged
joe merged 13 commits from ci into main 2022-09-28 18:02:57 +00:00
1 changed files with 43 additions and 0 deletions
Showing only changes of commit 99c032ec2c - Show all commits

43
.drone.yml Normal file
View File

@ -0,0 +1,43 @@
kind: pipeline
name: default
steps:
- name: build-ui
image: node:16.13-slim
volumes:
- name: temp
path: /app
commands:
- apt-get update
- apt-get -y install libssl-dev
- npm install
- npm run build
- cp -R ./ui/build /app/dist
- name: test
image: rust:latest
commands:
- rustup component add clippy
- cargo clippy
- cargo test --all
- name: binary-deploy
image: rust:latest
commands:
- cargo build --release
- tar cvzf mailspy.tar.gz -C target/release mailspy
- wget https://dl.min.io/client/mc/release/linux-amd64/mc
- chmod +x mc
- ./mc alias set fivesigma https://objects.5sigma.io $MINIOID $MINIOSECRET
- ./mc cp mailspy.tar.gz fivesigma/public/mailspy.tar.gz
# when:
# event:
# - promote
# target:
# - staging
# - production
volumes:
- name: temp
temp: {}