Dockerfile for installing Validation Framework in a CentOS container

Change-Id: I72b36d24fff0c621c7b97d93533a593ab68207e0
This commit is contained in:
Mathieu Bultel 2020-11-06 21:57:50 +01:00 committed by mbu
parent 276c20d88c
commit 5d43279cc4
2 changed files with 49 additions and 4 deletions

18
Dockerfile Normal file
View File

@ -0,0 +1,18 @@
FROM centos:latest
RUN dnf install -y git python3-pip gcc python3-devel
RUN git clone https://opendev.org/openstack/validations-libs /root/validations-libs
RUN git clone https://opendev.org/openstack/validations-common /root/validations-common
RUN cd /root/validations-libs && \
pip3 install -r requirements.txt && \
python3 setup.py install
RUN cd /root/validations-common && \
pip3 install -r requirements.txt && \
python3 setup.py install
RUN ln -s /usr/local/share/ansible /usr/share/ansible
RUN mkdir -p /var/log/validations

View File

@ -1,10 +1,37 @@
# validations-libs
================
validations-libs
================
A collection of python libraries for the Validation Framework
## Development Environment Setup
Development Environment Setup
=============================
Vagrantfiles for CentOS and Ubuntu have been provided for convenience; simply
copy one into your desired location and rename to `Vagrantfile`, then run
`vagrant up`. Once complete you will have a clean development environment
copy one into your desired location and rename to ``Vagrantfile``, then run::
vagrant up
Once complete you will have a clean development environment
ready to go for working with Validation Framework.
Docker Quickstart
=================
A Dockerfile is provided at the root of the Validations Library project in
order to quickly set and hack the Validation Framework.
Build the container from the Dockerfile by running::
docker build -t "vf:dockerfile" .
Once the build is finished you can check the image id::
docker images
Then you can run the container and start to run some builtin Validations::
docker run -ti <image_id> /bin/bash
Then run validations::
validation.py run --validation check-ftype,512e