summaryrefslogtreecommitdiffstats
path: root/bootstrap/vagrant-onap/tools/setup_libvirt.sh
blob: 54003d69186b67d707f338f561fc79fd6f187e07 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
#!/bin/bash

export VAGRANT_DEFAULT_PROVIDER=libvirt

source /etc/os-release || source /usr/lib/os-release
case ${ID,,} in
    *suse)
    ;;
    ubuntu|debian)
    # vagrant-libvirt dependencies
    sudo apt-get install -y qemu libvirt-bin ebtables dnsmasq libxslt-dev libxml2-dev libvirt-dev zlib1g-dev ruby-dev

    # NFS
    sudo apt-get install -y nfs-kernel-server
    ;;
    rhel|centos|fedora)
    PKG_MANAGER=$(which dnf || which yum)
    sudo $PKG_MANAGER install -y qemu libvirt libvirt-devel ruby-devel gcc qemu-kvm
    ;;
esac
vagrant plugin install vagrant-libvirt