simplify CI config
This commit is contained in:
parent
0d99bfa601
commit
458f39a6ed
56
.drone.yml
56
.drone.yml
|
@ -10,14 +10,10 @@ steps:
|
||||||
- name: check
|
- name: check
|
||||||
image: ayravat/rust:1.56.1-ci
|
image: ayravat/rust:1.56.1-ci
|
||||||
volumes:
|
volumes:
|
||||||
- name: ssh
|
|
||||||
path: /root/.ssh
|
|
||||||
- name: target
|
- name: target
|
||||||
path: /tmp/cargo-target
|
path: /tmp/cargo-target
|
||||||
- name: cache
|
- name: cache
|
||||||
path: /tmp/cargo
|
path: /tmp/cargo
|
||||||
- name: config
|
|
||||||
path: /root/.config/epp-client
|
|
||||||
commands:
|
commands:
|
||||||
- export CARGO_HOME=/tmp/cargo/$DRONE_BRANCH
|
- export CARGO_HOME=/tmp/cargo/$DRONE_BRANCH
|
||||||
- export CARGO_TARGET_DIR=/tmp/cargo-target/$DRONE_BRANCH
|
- export CARGO_TARGET_DIR=/tmp/cargo-target/$DRONE_BRANCH
|
||||||
|
@ -27,14 +23,10 @@ steps:
|
||||||
- name: fmt
|
- name: fmt
|
||||||
image: ayravat/rust:1.56.1-ci
|
image: ayravat/rust:1.56.1-ci
|
||||||
volumes:
|
volumes:
|
||||||
- name: ssh
|
|
||||||
path: /root/.ssh
|
|
||||||
- name: target
|
- name: target
|
||||||
path: /tmp/cargo-target
|
path: /tmp/cargo-target
|
||||||
- name: cache
|
- name: cache
|
||||||
path: /tmp/cargo
|
path: /tmp/cargo
|
||||||
- name: config
|
|
||||||
path: /root/.config/epp-client
|
|
||||||
commands:
|
commands:
|
||||||
- export CARGO_HOME=/tmp/cargo/$DRONE_BRANCH
|
- export CARGO_HOME=/tmp/cargo/$DRONE_BRANCH
|
||||||
- export CARGO_TARGET_DIR=/tmp/cargo-target/$DRONE_BRANCH
|
- export CARGO_TARGET_DIR=/tmp/cargo-target/$DRONE_BRANCH
|
||||||
|
@ -44,14 +36,10 @@ steps:
|
||||||
- name: clippy
|
- name: clippy
|
||||||
image: ayravat/rust:1.56.1-ci
|
image: ayravat/rust:1.56.1-ci
|
||||||
volumes:
|
volumes:
|
||||||
- name: ssh
|
|
||||||
path: /root/.ssh
|
|
||||||
- name: target
|
- name: target
|
||||||
path: /tmp/cargo-target
|
path: /tmp/cargo-target
|
||||||
- name: cache
|
- name: cache
|
||||||
path: /tmp/cargo
|
path: /tmp/cargo
|
||||||
- name: config
|
|
||||||
path: /root/.config/epp-client
|
|
||||||
commands:
|
commands:
|
||||||
- export CARGO_HOME=/tmp/cargo/$DRONE_BRANCH
|
- export CARGO_HOME=/tmp/cargo/$DRONE_BRANCH
|
||||||
- export CARGO_TARGET_DIR=/tmp/cargo-target/$DRONE_BRANCH
|
- export CARGO_TARGET_DIR=/tmp/cargo-target/$DRONE_BRANCH
|
||||||
|
@ -61,14 +49,10 @@ steps:
|
||||||
- name: test
|
- name: test
|
||||||
image: ayravat/rust:1.56.1-ci
|
image: ayravat/rust:1.56.1-ci
|
||||||
volumes:
|
volumes:
|
||||||
- name: ssh
|
|
||||||
path: /root/.ssh
|
|
||||||
- name: target
|
- name: target
|
||||||
path: /tmp/cargo-target
|
path: /tmp/cargo-target
|
||||||
- name: cache
|
- name: cache
|
||||||
path: /tmp/cargo
|
path: /tmp/cargo
|
||||||
- name: config
|
|
||||||
path: /root/.config/epp-client
|
|
||||||
commands:
|
commands:
|
||||||
- export CARGO_HOME=/tmp/cargo/$DRONE_BRANCH
|
- export CARGO_HOME=/tmp/cargo/$DRONE_BRANCH
|
||||||
- export CARGO_TARGET_DIR=/tmp/cargo-target/$DRONE_BRANCH
|
- export CARGO_TARGET_DIR=/tmp/cargo-target/$DRONE_BRANCH
|
||||||
|
@ -78,21 +62,17 @@ steps:
|
||||||
- name: crates.io
|
- name: crates.io
|
||||||
image: ayravat/rust:1.56.1-docker
|
image: ayravat/rust:1.56.1-docker
|
||||||
volumes:
|
volumes:
|
||||||
- name: ssh
|
|
||||||
path: /root/.ssh
|
|
||||||
- name: target
|
- name: target
|
||||||
path: /tmp/cargo-target
|
path: /tmp/cargo-target
|
||||||
- name: cache
|
- name: cache
|
||||||
path: /tmp/cargo
|
path: /tmp/cargo
|
||||||
- name: config
|
environment:
|
||||||
path: /root/.config/epp-client
|
CARGO_TOKEN:
|
||||||
- name: crates
|
from_secret: cargo_token
|
||||||
path: /root/.cargo
|
|
||||||
commands:
|
commands:
|
||||||
- export CARGO_HOME=/tmp/cargo/$DRONE_BRANCH
|
- export CARGO_HOME=/tmp/cargo/$DRONE_BRANCH
|
||||||
- export CARGO_TARGET_DIR=/tmp/cargo-target/$DRONE_BRANCH
|
- export CARGO_TARGET_DIR=/tmp/cargo-target/$DRONE_BRANCH
|
||||||
- mkdir -p $CARGO_HOME $CARGO_TARGET_DIR
|
- mkdir -p $CARGO_HOME $CARGO_TARGET_DIR
|
||||||
- export CARGO_TOKEN=$(cat $HOME/.cargo/credentials-token)
|
|
||||||
- cd epp-client
|
- cd epp-client
|
||||||
- cargo publish --token $CARGO_TOKEN
|
- cargo publish --token $CARGO_TOKEN
|
||||||
- cd ..
|
- cd ..
|
||||||
|
@ -106,32 +86,30 @@ steps:
|
||||||
|
|
||||||
- name: notify
|
- name: notify
|
||||||
image: drillster/drone-email
|
image: drillster/drone-email
|
||||||
volumes:
|
|
||||||
- name: notify-env
|
|
||||||
path: /root/.notify-env
|
|
||||||
environment:
|
environment:
|
||||||
PLUGIN_ENV_FILE: /root/.notify-env
|
PLUGIN_HOST:
|
||||||
|
from_secret: mail_host
|
||||||
|
PLUGIN_FROM:
|
||||||
|
from_secret: mail_sender
|
||||||
|
PLUGIN_FROM_NAME:
|
||||||
|
from_secret: mail_sender_name
|
||||||
|
PLUGIN_PORT:
|
||||||
|
from_secret: mail_port
|
||||||
|
PLUGIN_USERNAME:
|
||||||
|
from_secret: mail_user
|
||||||
|
PLUGIN_PASSWORD:
|
||||||
|
from_secret: mail_password
|
||||||
|
PLUGIN_RECIPIENTS:
|
||||||
|
from_secret: mail_recipients
|
||||||
when:
|
when:
|
||||||
status:
|
status:
|
||||||
- failure
|
- failure
|
||||||
|
|
||||||
volumes:
|
volumes:
|
||||||
- name: ssh
|
|
||||||
host:
|
|
||||||
path: /root/.ssh
|
|
||||||
- name: config
|
|
||||||
host:
|
|
||||||
path: /root/.config/epp-client
|
|
||||||
- name: crates
|
|
||||||
host:
|
|
||||||
path: /root/.cargo
|
|
||||||
- name: target
|
- name: target
|
||||||
host:
|
host:
|
||||||
path: /var/drone/cache/epp-client-target
|
path: /var/drone/cache/epp-client-target
|
||||||
- name: cache
|
- name: cache
|
||||||
host:
|
host:
|
||||||
path: /var/drone/cache/epp-client-cache
|
path: /var/drone/cache/epp-client-cache
|
||||||
- name: notify-env
|
|
||||||
host:
|
|
||||||
path: /root/.notify-env
|
|
||||||
...
|
...
|
||||||
|
|
Loading…
Reference in New Issue