vtk-m/Utilities/CI/DeveloperSetup.md
Robert Maynard 24a264fce8 Add scripts to allow developers to replicate CI environments
To simplify reproducing docker based CI workers locally, VTK-m has python program that handles all the
work automatically for you.

The program is located in `[Utilities/CI/reproduce_ci_env.py ]` and requires python3 and pyyaml.

To use the program is really easy! The following two commands will create the `build:rhel8` gitlab-ci
worker as a docker image and setup a container just as how gitlab-ci would be before the actual
compilation of VTK-m. Instead of doing the compilation, instead you will be given an interactive shell.

```
./reproduce_ci_env.py create rhel8
./reproduce_ci_env.py run rhel8
```

To compile VTK-m from the the interactive shell you would do the following:
```
> src]# cd build/
> build]# cmake --build .
```
2020-04-09 13:54:20 -04:00

716 B

#How to setup machine to use CI scripts#

#OSX and Unix#

Requirements

  • Docker
  • Python3 -- PyYAML

The CI scripts require python3 and the PyYAML package.

Generally the best way to setup this environment is to create a python virtual env so you don't pollute your system. This means getting pip the python package manager, and virtual env which allow for isolation of a projects python dependencies.

sudo easy_install pip
sudo pip install virtualenv

Next we need to create a new virtual env of python. I personally like to setup this in vtkm/Utilities/CI/env.

mkdir env
virtualenv env

Now all we have to do is setup the requirements:

./env/bin/pip install -r requirements.txt