Files
ortools-clone/makefiles/docs/ci.md
Corentin Le Molgat 2a80c2e115 fixup doc
2022-02-25 08:05:16 +01:00

44 lines
995 B
Markdown

# CI: Makefile/Docker testing
To test the build on various distro, I'm using docker containers and a Makefile
for orchestration.
pros:
* You are independent of third party CI runner config (e.g. github actions
runners or Travis-CI VM images).
* You can run it locally on your linux system.
* Most CI provide runner with docker and Makefile installed (e.g. tarvis-ci
[minimal images](https://docs.travis-ci.com/user/languages/minimal-and-generic/).
cons:
* Only GNU/Linux distro supported.
* Could take few GiB (~30 GiB for all distro and all languages)
* ~500MiB OS + C++/CMake tools,
* ~150 MiB Python,
* ~400 MiB dotnet-sdk,
* ~400 MiB java-jdk.
## Usage
To get the help simply type:
```sh
make
```
note: you can also use from top directory
```sh
make --directory=makefiles
```
### Example
For example to test `Python` inside an `Alpine` container:
```sh
make alpine_python_test
```
## Docker layers
Dockerfile is split in several stages.
![docker](docker.svg)