Hello,

I would like to share my script that allows to create topology for FreeIPA CI tests in Vagrant. It is very first "stupid" version, works only with F22 box. It is useful for development.
Script creates Vagrant configuration and CI configuration for YAML.

Machines created by vagrant are named:
controller  (created by default)
master  (created by default)
replica1  (--replicas option)
.
.
replicaN
client1  (--client option)
.
.
clientM

The script is available here https://github.com/bastiak/ipa-devel-tools

Required packages: vagrant vagrant-libvirt PyYAML

Usage:
$python3 ipa-vagrant-ci-topology-create.py ci-test --replicas 1 --clients 1

$python3 ipa-vagrant-ci-topology-create.py -h
Use --help for more options

It creates directory structure in current location
.
├── ci-test
│   ├── controller_rsa  # generated private key for controller
│ ├── controller_rsa.pub # generated public key for controller (needed by CI tests)
│   ├── ipa-test-config.yaml  # generated configuration for CI tests
│   ├── provisioning  # currently empty dir, but I have big plans with it :)
│   ├── rpms  # custom RPMs that will be installed on all machines
│   └── Vagrantfile  # generated configration file for Vagrant

$ cd ci-test
<copy custom RPMs to rpms/ directory>
$ vagrant up
$ vagrant ssh [controller|master|replica1|...] (by default it open connection to controller machine) $IPATEST_YAML_CONFIG=/vagrant/ipa-test-config.yaml ipa-run-tests test_integration/test_simple_replication.py # configuration file is located in /vagrant directory
<enjoy test>
$ logout
$ vagrant destroy


Martin

--
Manage your subscription for the Freeipa-devel mailing list:
https://www.redhat.com/mailman/listinfo/freeipa-devel
Contribute to FreeIPA: http://www.freeipa.org/page/Contribute/Code

Reply via email to