add some missing “set -ue” declarations

Since 79ab95b16e78d563c473b5acada62cb3e22d4eb1 dib-lint ensure
every element shell scripts have “set -e” activated.

Even if dib-lint doesn't test it yet, the set -u is already widely
used.

As pointed out by Jiri Stransky, elements/tripleo-cd/configs/* files
are sourced by deploy-testenv. There is no reason to enable “set -ue”
manually. The patch just disable the dib-lint “sete” check on these files.

Change-Id: I118c8c80ec50b265c22577b075d15f56389b7a47
This commit is contained in:
Gonéri Le Bouder 2014-05-10 18:07:25 +02:00
parent af4306ecbb
commit 25a962a6eb
18 changed files with 26 additions and 0 deletions

View File

@ -1,4 +1,6 @@
#!/bin/bash
set -ue
install -m 0755 -o root -g root $(dirname $0)/../bin/filter-bootps /usr/local/bin/filter-bootps
cat > /etc/cron.d/filter-bootps <<EOF
# Ensure we don't answer BOOTP for bare metal nodes not registered with nova.

View File

@ -1,4 +1,6 @@
#!/bin/bash
set -ue
[ -d /mnt/state/var/lib/glance ] || install -d -D -m 0770 -o glance -g glance /mnt/state/var/lib/glance
[ -d /mnt/state/var/lib/glance/images ] || install -d -D -m 0770 -o glance -g glance /mnt/state/var/lib/glance/images
[ -d /mnt/state/var/log/glance ] || install -d -D -m 0755 -o glance -g glance /mnt/state/var/log/glance

View File

@ -1,4 +1,5 @@
#!/bin/bash
set -ue
os-svc-enable -n heat-api
os-svc-enable -n heat-api-cfn

View File

@ -1,4 +1,6 @@
#!/bin/bash
set -ue
# If https://bugs.launchpad.net/heat/+bug/1239377 is ever fixed we can
# configure heat to purge automatically and remove this.
cat <<EOF > /etc/cron.d/heat

View File

@ -1,4 +1,5 @@
#!/bin/bash
set -ue
# The mariadb download url arch values are not the same as ours
if [ $ARCH = "i386" ]; then

View File

@ -1,4 +1,5 @@
#!/bin/bash
set -ue
# The percona download url arch values are not the same as ours
if [ $ARCH = "amd64" ]; then

View File

@ -1,4 +1,6 @@
#!/bin/bash
set -ue
# potentially thousands of network interfaces on the system, we don't
# want to overwhelm upstart with log pipes. This sends all of it to the
# system console.

View File

@ -1,4 +1,5 @@
#!/bin/bash
set -ue
set -x
SCRIPTDIR=$(dirname $0)

View File

@ -1,3 +1,5 @@
#!/bin/bash
set -ue
os-svc-daemon -i "$NEUTRON_VENV_DIR" neutron-server neutron neutron-server \
"--config-file /etc/neutron/neutron.conf --config-file /etc/neutron/plugins/ml2/ml2_conf.ini --config-dir /etc/neutron"

View File

@ -1,4 +1,6 @@
#!/bin/bash
set -ue
[ -d /mnt/state/var/lib/nova ] && exit 0
install -D -d -o nova -g nova -m 0775 /mnt/state/var/lib/nova
[ -d /mnt/state/var/log/nova ] && exit 0

View File

@ -1,3 +1,5 @@
#!/bin/bash
set -ue
# ntpdate is used when the network is brought up to correct any large time skew
install-packages ntp ntpdate

View File

@ -1,4 +1,5 @@
#!/bin/bash
set -ue
# ceilometerclient
if [ -z "${CEILOMETERCLIENT_VENV_DIR:-}" ]; then

View File

@ -1,2 +1,4 @@
#!/bin/bash
set -ue
exec os-apply-config

View File

@ -1,4 +1,5 @@
#!/bin/bash
set -ue
install-packages qpidd qpid-tools qpid-client

View File

@ -1,4 +1,5 @@
#!/bin/bash
# dib-lint: disable=sete
source $TRIPLEO_ROOT/tripleo-incubator/scripts/set-os-type
if [ $TRIPLEO_OS_DISTRO = "fedora" ] ; then

View File

@ -1,4 +1,5 @@
#!/bin/bash
# dib-lint: disable=sete
export TRIPLEO_ROOT="$(readlink -f $(dirname $0)/../../../..)"
source $(dirname ${BASH_SOURCE})/te_commonrc

View File

@ -1,4 +1,5 @@
#!/bin/bash
# dib-lint: disable=sete
export TRIPLEO_ROOT="$(readlink -f $(dirname $0)/../../../..)"
source $(dirname ${BASH_SOURCE})/te_commonrc

View File

@ -1,4 +1,5 @@
#!/bin/bash
# dib-lint: disable=sete
export TRIPLEO_ROOT="$(readlink -f $(dirname $0)/../../../..)"
source $(dirname ${BASH_SOURCE})/te_commonrc