mailspy/.drone.yml

46 lines
883 B
YAML

kind: pipeline
name: default
steps:
- name: build-ui
image: node:18.9.1-slim
volumes:
- name: temp
path: /app
commands:
- apt-get update
- apt-get -y install libssl-dev
- cd ui
- npm install
- npm run build
- cp -R ./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:
- cp -R /app/dist ./ui/build
- 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: {}