Renamed the conf templates to an actual template folder and adjusted due to this.
This commit is contained in:
parent
a6259ea355
commit
ab01dec573
conf/nova
devstack
templates
glance
horizon
keystone
nova
swift
@ -1,47 +0,0 @@
|
||||
Cmnd_Alias NOVADEVCMDS = /bin/chmod /var/lib/nova/tmp/*/root/.ssh, \
|
||||
/bin/chown /var/lib/nova/tmp/*/root/.ssh, \
|
||||
/bin/chown, \
|
||||
/bin/chmod, \
|
||||
/bin/dd, \
|
||||
/sbin/ifconfig, \
|
||||
/sbin/ip, \
|
||||
/sbin/route, \
|
||||
/sbin/iptables, \
|
||||
/sbin/iptables-save, \
|
||||
/sbin/iptables-restore, \
|
||||
/sbin/ip6tables-save, \
|
||||
/sbin/ip6tables-restore, \
|
||||
/sbin/kpartx, \
|
||||
/sbin/losetup, \
|
||||
/sbin/lvcreate, \
|
||||
/sbin/lvdisplay, \
|
||||
/sbin/lvremove, \
|
||||
/bin/mkdir, \
|
||||
/bin/mount, \
|
||||
/sbin/pvcreate, \
|
||||
/usr/bin/tee, \
|
||||
/sbin/tune2fs, \
|
||||
/bin/umount, \
|
||||
/sbin/vgcreate, \
|
||||
/usr/bin/virsh, \
|
||||
/usr/bin/qemu-nbd, \
|
||||
/usr/sbin/brctl, \
|
||||
/sbin/brctl, \
|
||||
/usr/sbin/radvd, \
|
||||
/usr/sbin/vblade-persist, \
|
||||
/sbin/pvcreate, \
|
||||
/sbin/aoe-discover, \
|
||||
/sbin/vgcreate, \
|
||||
/bin/aoe-stat, \
|
||||
/bin/kill, \
|
||||
/sbin/vconfig, \
|
||||
/usr/sbin/ietadm, \
|
||||
/sbin/vgs, \
|
||||
/sbin/iscsiadm, \
|
||||
/usr/bin/socat, \
|
||||
/sbin/parted, \
|
||||
/usr/sbin/dnsmasq, \
|
||||
/usr/sbin/arping
|
||||
|
||||
%USER% ALL = (root) NOPASSWD: SETENV: NOVADEVCMDS
|
||||
|
@ -178,7 +178,7 @@ QUANTUM_OPENSWITCH_OPS = {
|
||||
}
|
||||
|
||||
#this is a special conf
|
||||
CLEANER_DATA_CONF = 'clean_iptables.sh'
|
||||
CLEANER_DATA_CONF = 'nova-clean-network.sh'
|
||||
CLEANER_CMD_ROOT = [sh.joinpths("/", "bin", 'bash')]
|
||||
|
||||
#pip files that nova requires
|
||||
@ -298,6 +298,7 @@ class NovaInstaller(comp.PythonInstallComponent):
|
||||
(_, contents) = utils.load_template(self.component_name, CLEANER_DATA_CONF)
|
||||
tgt_fn = sh.joinpths(self.bindir, CLEANER_DATA_CONF)
|
||||
sh.write_file(tgt_fn, contents)
|
||||
self.tracewriter.file_touched(tgt_fn)
|
||||
|
||||
def _setup_db(self):
|
||||
LOG.info("Fixing up database named %s.", DB_NAME)
|
||||
|
@ -105,9 +105,9 @@ START = "start"
|
||||
STOP = "stop"
|
||||
ACTIONS = [INSTALL, UNINSTALL, START, STOP]
|
||||
|
||||
# Where we should get the config file and where stacks config
|
||||
# directory is
|
||||
# Where the configs and templates should be at.
|
||||
STACK_CONFIG_DIR = "conf"
|
||||
STACK_TEMPLATE_DIR = "templates"
|
||||
STACK_PKG_DIR = os.path.join(STACK_CONFIG_DIR, "pkgs")
|
||||
STACK_PIP_DIR = os.path.join(STACK_CONFIG_DIR, "pips")
|
||||
STACK_CONFIG_LOCATION = os.path.join(STACK_CONFIG_DIR, "stack.ini")
|
||||
|
@ -39,8 +39,9 @@ LOG = logging.getLogger("devstack.util")
|
||||
TEMPLATE_EXT = ".tpl"
|
||||
|
||||
|
||||
def load_template(component, fn):
|
||||
full_pth = sh.joinpths(settings.STACK_CONFIG_DIR, component, fn + TEMPLATE_EXT)
|
||||
def load_template(component, template_name):
|
||||
fn = template_name + TEMPLATE_EXT
|
||||
full_pth = sh.joinpths(settings.STACK_TEMPLATE_DIR, component, fn)
|
||||
contents = sh.load_file(full_pth)
|
||||
return (full_pth, contents)
|
||||
|
||||
|
@ -1,16 +1,16 @@
|
||||
#!/bin/bash
|
||||
|
||||
# This script cleans up the iptables as part of a nova uninstall
|
||||
# This script cleans up the network as part of a nova uninstall
|
||||
|
||||
# Eventually it should be moved to python code...
|
||||
|
||||
# Ignore any errors from shutting down dnsmasq
|
||||
# TODO shouldn't this be a service shutdown??
|
||||
killall dnsmasq
|
||||
|
||||
# This was added (so that it dies on errors)
|
||||
set -o errexit
|
||||
|
||||
|
||||
# Delete rules
|
||||
iptables -S -v | sed "s/-c [0-9]* [0-9]* //g" | grep "nova" | grep "\-A" | sed "s/-A/-D/g" | awk '{print "sudo iptables",$0}' | bash
|
||||
|
Loading…
x
Reference in New Issue
Block a user