2021-02-08 15:32:29 +00:00
|
|
|
kind: pipeline
|
|
|
|
name: default
|
|
|
|
|
2021-02-17 17:46:36 +00:00
|
|
|
workspace:
|
2021-03-18 16:45:26 +00:00
|
|
|
base: /drone/garage
|
2021-02-17 17:46:36 +00:00
|
|
|
|
2021-02-08 15:32:29 +00:00
|
|
|
steps:
|
|
|
|
- name: restore-cache
|
|
|
|
image: meltwater/drone-cache:dev
|
|
|
|
environment:
|
|
|
|
AWS_ACCESS_KEY_ID:
|
|
|
|
from_secret: cache_aws_access_key_id
|
|
|
|
AWS_SECRET_ACCESS_KEY:
|
|
|
|
from_secret: cache_aws_secret_access_key
|
|
|
|
pull: true
|
|
|
|
settings:
|
|
|
|
restore: true
|
2021-02-10 12:11:13 +00:00
|
|
|
archive_format: "gzip"
|
2021-02-08 15:32:29 +00:00
|
|
|
bucket: drone-cache
|
2021-03-19 13:15:19 +00:00
|
|
|
cache_key: '{{ .Repo.Name }}_{{ checksum "Cargo.lock" }}_{{ arch }}_{{ os }}_gzip'
|
2021-02-08 15:32:29 +00:00
|
|
|
region: garage
|
|
|
|
mount:
|
2021-03-18 16:45:26 +00:00
|
|
|
- 'target'
|
|
|
|
- '/drone/cargo/registry/index'
|
|
|
|
- '/drone/cargo/registry/cache'
|
|
|
|
- '/drone/cargo/bin'
|
|
|
|
- '/drone/cargo/git/db'
|
2021-02-08 15:32:29 +00:00
|
|
|
path_style: true
|
|
|
|
endpoint: https://garage.deuxfleurs.fr
|
|
|
|
|
|
|
|
- name: build
|
2021-02-08 13:58:24 +00:00
|
|
|
image: rust:buster
|
2021-02-17 17:46:36 +00:00
|
|
|
environment:
|
|
|
|
CARGO_HOME: /drone/cargo
|
2021-02-08 13:58:24 +00:00
|
|
|
commands:
|
|
|
|
- apt-get update
|
2021-02-08 14:02:03 +00:00
|
|
|
- apt-get install --yes libsodium-dev
|
2021-02-17 17:46:36 +00:00
|
|
|
- pwd
|
2021-02-08 13:58:24 +00:00
|
|
|
- cargo build
|
|
|
|
|
2021-02-17 17:46:36 +00:00
|
|
|
- name: cargo-test
|
|
|
|
image: rust:buster
|
|
|
|
environment:
|
|
|
|
CARGO_HOME: /drone/cargo
|
|
|
|
commands:
|
|
|
|
- apt-get update
|
|
|
|
- apt-get install --yes libsodium-dev
|
|
|
|
- cargo test
|
|
|
|
|
2021-02-08 15:32:29 +00:00
|
|
|
- name: rebuild-cache
|
|
|
|
image: meltwater/drone-cache:dev
|
|
|
|
environment:
|
|
|
|
AWS_ACCESS_KEY_ID:
|
|
|
|
from_secret: cache_aws_access_key_id
|
|
|
|
AWS_SECRET_ACCESS_KEY:
|
|
|
|
from_secret: cache_aws_secret_access_key
|
|
|
|
pull: true
|
|
|
|
settings:
|
|
|
|
rebuild: true
|
2021-02-10 11:53:00 +00:00
|
|
|
archive_format: "gzip"
|
2021-02-08 15:32:29 +00:00
|
|
|
bucket: drone-cache
|
2021-03-19 13:15:19 +00:00
|
|
|
cache_key: '{{ .Repo.Name }}_{{ checksum "Cargo.lock" }}_{{ arch }}_{{ os }}_gzip'
|
2021-02-08 15:32:29 +00:00
|
|
|
region: garage
|
|
|
|
mount:
|
2021-03-18 16:45:26 +00:00
|
|
|
- 'target'
|
|
|
|
- '/drone/cargo/registry/index'
|
|
|
|
- '/drone/cargo/registry/cache'
|
|
|
|
- '/drone/cargo/git/db'
|
|
|
|
- '/drone/cargo/bin'
|
2021-02-08 15:32:29 +00:00
|
|
|
path_style: true
|
|
|
|
endpoint: https://garage.deuxfleurs.fr
|
2021-02-17 17:46:36 +00:00
|
|
|
|
|
|
|
- name: smoke-test
|
|
|
|
image: rust:buster
|
|
|
|
environment:
|
|
|
|
CARGO_HOME: /drone/cargo
|
|
|
|
commands:
|
|
|
|
- apt-get update
|
|
|
|
- apt-get install --yes libsodium-dev awscli python-pip
|
|
|
|
- pip install s3cmd
|
|
|
|
- ./script/test-smoke.sh || (cat /tmp/garage.log; false)
|
2021-03-19 13:25:57 +00:00
|
|
|
|
|
|
|
---
|
|
|
|
kind: pipeline
|
|
|
|
name: website
|
|
|
|
|
|
|
|
steps:
|
|
|
|
- name: build
|
|
|
|
image: hrektts/mdbook
|
|
|
|
commands:
|
|
|
|
- cd doc/book
|
|
|
|
- mdbook build
|
|
|
|
|
|
|
|
- name: upload
|
|
|
|
image: plugins/s3
|
|
|
|
settings:
|
|
|
|
bucket: garagehq.deuxfleurs.fr
|
|
|
|
access_key:
|
|
|
|
from_secret: garagehq_aws_access_key_id
|
|
|
|
secret_key:
|
|
|
|
from_secret: garagehq_aws_secret_access_key
|
|
|
|
source: doc/book/book/**/*
|
|
|
|
strip_prefix: doc/book/book/
|
|
|
|
target: /
|
|
|
|
path_style: true
|
|
|
|
endpoint: https://garage.deuxfleurs.fr
|
|
|
|
region: garage
|
2021-03-19 13:29:37 +00:00
|
|
|
when:
|
|
|
|
branch:
|
|
|
|
- main
|
2021-03-22 11:49:11 +00:00
|
|
|
repo:
|
|
|
|
- Deuxfleurs/garage
|
2021-03-19 13:25:57 +00:00
|
|
|
|
2021-04-05 10:08:05 +00:00
|
|
|
---
|