22 lines
617 B
Bash
Executable File
22 lines
617 B
Bash
Executable File
#!/bin/bash
|
|
set -eux
|
|
|
|
DISTRO=`lsb_release -si` || true
|
|
|
|
install-packages openvswitch-switch openvswitch-datapath-dkms
|
|
os-svc-install -n quantum -u quantum -r https://github.com/openstack/neutron.git
|
|
|
|
mkdir -p /var/lib/quantum && chown -R quantum:quantum /var/lib/quantum
|
|
|
|
ln -sf /opt/stack/venvs/quantum/bin/quantum-rootwrap /usr/bin/quantum-rootwrap
|
|
ln -sf /opt/stack/venvs/quantum/etc/quantum/rootwrap.d /etc/quantum/rootwrap.d
|
|
|
|
echo "quantum ALL=(root) NOPASSWD:ALL" > /etc/sudoers.d/quantum
|
|
chmod 0440 /etc/sudoers.d/quantum
|
|
visudo -c
|
|
|
|
if [ $DISTRO = "Fedora" ]; then
|
|
systemctl enable openvswitch.service
|
|
fi
|
|
|