commands:
make: !Command
description: Build lithos in ubuntu container
container: xenial
run: [cargo, build]
test: !Command
description: Run cargo tests
container: xenial
run: [cargo, test]
_static-lithos_check-package: !Command
description: Build static lithos_check package (.tar.gz)
container: rust-musl
run: |
cargo build --target=x86_64-unknown-linux-musl
tar -czf dist/lithos-check-$(git describe).tar.gz \
-C target/x86_64-unknown-linux-musl/debug lithos_check
cargo: !Command
description: Run any cargo command
container: xenial
symlink-name: cargo
run: [cargo]
bulk: !Command
description: Run any bulk command
container: xenial
run: [bulk]
doc: !Command
description: Build HTML docs
container: docs
work-dir: docs
run: [make, html]
make-docs: !Command
description: Build
container: docs
work-dir: docs
run: [make]
_package-trusty: !Command
container: trusty
run: [make, ubuntu-packages]
_package-xenial: !Command
container: xenial
run: [make, ubuntu-packages]
_package-bionic: !Command
container: bionic
run: [make, ubuntu-packages]
_package-lithos_check: !Command
container: rust-musl
run: [make, ubuntu-lithos_check-package]
packages: !Command
container: xenial
description: Build packages and repostories (mostly for CI)
prerequisites: [_package-trusty, _package-xenial, _package-bionic,
_package-lithos_check]
accepts_arguments: true
run: |
bulk repo-add --config bulk-check.yaml \
--repository-base dist/repos \
dist/lithos-check-*.deb "$@"
bulk repo-add --config bulk.yaml --repository-base dist/repos \
dist/lithos-[0-9]*.deb "$@"
containers:
py-example:
setup:
- !Alpine v3.3
- !Install [python3]
- !EnsureDir /config
- !EnsureDir /code
- !Copy
source: /work/examples/py/code/sock.py
path: /code/sock.py
- !Copy
source: /work/examples/py/code/socket.yaml
path: /config/socket.yaml
- !Copy
source: /work/examples/py/code/py.yaml
path: /config/py.yaml
py_var-example:
setup:
- !Alpine v3.3
- !Install [python3]
- !EnsureDir /config
- !EnsureDir /code
- !Copy
source: /work/examples/py_var/code/sock.py
path: /code/sock.py
- !Copy
source: /work/examples/py_var/code/socket.yaml
path: /config/socket.yaml
- !Copy
source: /work/examples/py_var/code/py.yaml
path: /config/py.yaml
multi_level-example:
setup:
- !Alpine v3.6
- !Install [python3]
- !EnsureDir /config
- !EnsureDir /code
- !Copy
source: /work/examples/multi_level/code/sock.py
path: /code/sock.py
- !Copy
source: /work/examples/multi_level/code/socket.yaml
path: /config/socket.yaml
- !Copy
source: /work/examples/multi_level/code/py.yaml
path: /config/py.yaml
xenial:
setup:
- !Ubuntu xenial
- &pkgs !Install [make, gcc, libc-dev, ca-certificates, git, lsb-release, vim]
- &rust !TarInstall
url: https://static.rust-lang.org/dist/rust-1.25.0-x86_64-unknown-linux-gnu.tar.gz
script: "./install.sh --prefix=/usr --components=rustc,cargo \
--components=rustc,rust-std-x86_64-unknown-linux-gnu,cargo"
- &bulk !Tar
url: "https://github.com/tailhook/bulk/releases/download/v0.4.9/bulk-v0.4.9.tar.gz"
sha256: 23471a9986274bb4b7098c03e2eb7e1204171869b72c45385fcee1c64db2d111
path: /
environ: &environ
HOME: /work/target
trusty:
setup:
- !Ubuntu trusty
- *pkgs
- *rust
- *bulk
environ: *environ
bionic:
setup:
- !Ubuntu bionic
- *pkgs
- *rust
- *bulk
environ: *environ
rust-musl:
environ: &rustenv
LD_LIBRARY_PATH: /musl/lib/rustlib/x86_64-unknown-linux-musl/lib
PATH: /musl/bin:/usr/local/bin:/usr/bin:/bin
HOME: /work/target
setup:
- !Ubuntu xenial
- !UbuntuUniverse
- !Install [musl-tools]
- *pkgs
- *rust
- !TarInstall
url: "https://static.rust-lang.org/dist/rust-std-1.25.0-x86_64-unknown-linux-musl.tar.gz"
script: "./install.sh --prefix=/musl \
--components=rust-std-x86_64-unknown-linux-musl"
- !Sh 'ln -s /musl/lib/rustlib/x86_64-unknown-linux-musl /usr/lib/rustlib/x86_64-unknown-linux-musl'
- *bulk
docs:
setup:
- !Alpine v3.1
- !Install [py-sphinx, make]
- !Py2Requirements "docs/requirements.txt"