Modularity-tools

Requirements

Following packages are required: * python2-pytest

build_oc_template.py

The tool is used for generation OpenShift template from Dockerfile and from https://github.com/container-images/container-image-template/blob/master/openshift-template.yml already prepared by Modularity team. As Dockerfile as openshift-template.yml have to exist in the directory.

How to use build_oc_template.py

Run the command with following parameters:

./build_oc_template.py --dockerfile <full_path_to_Dockerfile> IMAGENAME

where parameters mean: * dockerfile ... means full path to Dockerfile * IMAGENAME ... means image name in register. Can be taken from command docker images or from some other registry.

The output of build_oc_template.py command is OpenShift template stored in temporary directory

Example usage:

   ./build_oc_template.py --dockerfile ~/work/programming/container-images/debugging-tools/Dockerfile registry.fedoraproject.org/debugging-tools
/home/phracek/work/programming/container-images/debugging-tools/Dockerfile
   OpenShift template is generated here: /tmp/tmpM0teUC/openshift-template.yml

How to run tests for build_oc_template.py

In order to run tests, run command:

py.test-2.7 tests/

Base Run Time dependency solver

  • ./brt_dep_solver.sh <package> - produce files with dependencies

For verbose output set variable VERBOSE to true:

# VERBOSE=true ./brt_dep_solver.sh <package>

For debugging you might want to keep all files generated by dependecy solver (not just the ones with resuls). Set variable CLEAN to false to keep all these files.

# VERBOSE=false ./brt_dep_solver.sh <package>