add Vagrantfile for Validation Framework dev work
Added a development environment shortcut by way of Vagrantfiles for CentOS and Ubuntu; also updated README.rst to indicate usage. Change-Id: I561ecd6cede3c5cdb7605e368d2b031b05612133
This commit is contained in:
parent
c727b7c2ac
commit
c59ea3016f
@ -1,3 +1,10 @@
|
|||||||
# validations-libs
|
# validations-libs
|
||||||
|
|
||||||
A collection of python libraries for the Validation Framework
|
A collection of python libraries for the Validation Framework
|
||||||
|
|
||||||
|
## 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
|
||||||
|
ready to go for working with Validation Framework.
|
||||||
|
28
Vagrantfile.centos
Normal file
28
Vagrantfile.centos
Normal file
@ -0,0 +1,28 @@
|
|||||||
|
Vagrant.configure("2") do |config|
|
||||||
|
config.vm.box = "centos/8"
|
||||||
|
config.vm.box_version = "1905.1"
|
||||||
|
config.vm.provider "virtualbox" do |vb|
|
||||||
|
vb.memory = "2048"
|
||||||
|
end
|
||||||
|
config.vm.provision "shell", inline: <<-SHELL
|
||||||
|
echo "export TERM=xterm">>/home/vagrant/.bashrc
|
||||||
|
echo "export TERM=xterm">>/root/.bashrc
|
||||||
|
dnf update -y
|
||||||
|
dnf install -y epel-release
|
||||||
|
yum-config-manager --disable epel
|
||||||
|
dnf install -y python3-devel gcc git vim
|
||||||
|
dnf install -y --enablerepo epel ansible
|
||||||
|
git clone https://opendev.org/openstack/validations-libs
|
||||||
|
git clone https://opendev.org/openstack/validations-common
|
||||||
|
pushd validations-libs
|
||||||
|
sudo -u vagrant pip3 install --user -r requirements.txt
|
||||||
|
python3 setup.py install
|
||||||
|
popd
|
||||||
|
pushd validations-common
|
||||||
|
sudo -u vagrant pip3 install --user -r requirements.txt
|
||||||
|
python3 setup.py install
|
||||||
|
popd
|
||||||
|
ln -s /usr/local/share/ansible/validations-playbooks /usr/share/ansible/validations-playbooks
|
||||||
|
mkdir -p /var/log/validations
|
||||||
|
SHELL
|
||||||
|
end
|
25
Vagrantfile.ubuntu
Normal file
25
Vagrantfile.ubuntu
Normal file
@ -0,0 +1,25 @@
|
|||||||
|
Vagrant.configure("2") do |config|
|
||||||
|
config.vm.box = "ubuntu/focal64"
|
||||||
|
config.vm.provider "virtualbox" do |vb|
|
||||||
|
vb.memory = "2048"
|
||||||
|
end
|
||||||
|
config.vm.provision "shell", inline: <<-SHELL
|
||||||
|
echo "export TERM=xterm">>/home/vagrant/.bashrc
|
||||||
|
echo "export TERM=xterm">>/root/.bashrc
|
||||||
|
apt-get -y update
|
||||||
|
apt-get -y upgrade
|
||||||
|
apt-get -y install ansible git python3-pip vim
|
||||||
|
git clone https://opendev.org/openstack/validations-libs
|
||||||
|
git clone https://opendev.org/openstack/validations-common
|
||||||
|
pushd validations-libs
|
||||||
|
pip3 install -r requirements.txt
|
||||||
|
python3 setup.py install
|
||||||
|
popd
|
||||||
|
pushd validations-common
|
||||||
|
pip3 install -r requirements.txt
|
||||||
|
python3 setup.py install
|
||||||
|
popd
|
||||||
|
ln -s /usr/local/share/validations-common /usr/share/validations-common
|
||||||
|
mkdir -p /var/log/validations
|
||||||
|
SHELL
|
||||||
|
end
|
Loading…
x
Reference in New Issue
Block a user