Merge branch 'ci' into 'main'
Set-up CI See merge request kernald/immich-tools!1
This commit is contained in:
commit
5eb1e3bba4
1 changed files with 62 additions and 0 deletions
62
.gitlab-ci.yml
Normal file
62
.gitlab-ci.yml
Normal file
|
@ -0,0 +1,62 @@
|
|||
---
|
||||
stages:
|
||||
- test
|
||||
- build
|
||||
- publish
|
||||
|
||||
|
||||
default:
|
||||
|
||||
tests:
|
||||
stage: test
|
||||
image: rust
|
||||
before_script:
|
||||
- rustc --version
|
||||
- cargo --version
|
||||
- rustup component add rustfmt
|
||||
script:
|
||||
- cargo fmt --check
|
||||
- cargo test
|
||||
|
||||
build:amd64:
|
||||
stage: build
|
||||
image: rust
|
||||
before_script:
|
||||
- rustc --version
|
||||
- cargo --version
|
||||
script:
|
||||
- cargo build --release
|
||||
artifacts:
|
||||
paths:
|
||||
- target/release/immich-tools
|
||||
|
||||
rustdoc:
|
||||
stage: build
|
||||
image: rust
|
||||
before_script:
|
||||
- rustc --version
|
||||
- cargo --version
|
||||
script:
|
||||
- cargo doc
|
||||
artifacts:
|
||||
paths:
|
||||
- target/doc
|
||||
|
||||
pages:
|
||||
stage: publish
|
||||
image: alpine
|
||||
dependencies:
|
||||
- build:amd64
|
||||
- rustdoc
|
||||
script:
|
||||
- mkdir -p public
|
||||
- mv target/doc public/doc
|
||||
- mv target/release/immich-tools public/immich-tools-amd64
|
||||
artifacts:
|
||||
paths:
|
||||
- public
|
||||
only:
|
||||
- main
|
||||
...
|
||||
|
||||
|
Loading…
Add table
Add a link
Reference in a new issue