> Le 23 août 2017 à 15:52, Yaniv Kaul <yk...@redhat.com> a écrit : > > > > On Wed, Aug 23, 2017 at 1:11 PM, Fabrice Bacchella > <fabrice.bacche...@orange.fr <mailto:fabrice.bacche...@orange.fr>> wrote: > I'm still playing with my sdk4 python wrapper > (https://github.com/fbacchella/ovirtcmd > <https://github.com/fbacchella/ovirtcmd>). > > In the last update, I tried to make writing of custom script simpler. > > As an example, i wrote a wrapper for single node cluster installation. > > I have a bunch of old ProLiant DL185 G5. I configured them to be single-node > cluster. I create two disks on them, one will be system, the second on will > be directly used by oVirt, without a file system on it. Three VLAN are added > to the server. It used with: > > ovcmd eval -v host_name $hostname samples/single_node_cluster.py > > The code for this script is found at > https://github.com/fbacchella/ovirtcmd/blob/master/samples/single_node_cluster.py > > <https://github.com/fbacchella/ovirtcmd/blob/master/samples/single_node_cluster.py> > > > Thanks for sharing. I quite like ovlib. > How do you pass parameters to the script?
It's prepared in the variables of the eval. The argument -v host_name $hostname create a variable called hostname with value $hostname that will be global for the script. > > Lastly, I wonder how it compares to oVirt Ansible roles[1]. I don't know, I'm not a ansible user, we're running on puppet.
_______________________________________________ Users mailing list Users@ovirt.org http://lists.ovirt.org/mailman/listinfo/users