Wrap some overly long lines
To cut down on noise when running bashate, wrap some overlong lines. Change-Id: I23dcffbae2539d3d6b11e5527f3d4cbf08a18064
This commit is contained in:
@@ -27,7 +27,8 @@ then
|
|||||||
# Delete everything so the first commit is truly empty:
|
# Delete everything so the first commit is truly empty:
|
||||||
git rm -rf .
|
git rm -rf .
|
||||||
# git rm -rf leaves submodule directories:
|
# git rm -rf leaves submodule directories:
|
||||||
find -maxdepth 1 -not -regex '\./\.git\(/.*\)?' -not -name . -exec rm -fr {} \;
|
find -maxdepth 1 -not -regex '\./\.git\(/.*\)?' -not -name . \
|
||||||
|
-exec rm -fr {} \;
|
||||||
ls -la
|
ls -la
|
||||||
else
|
else
|
||||||
git branch -D release || /bin/true
|
git branch -D release || /bin/true
|
||||||
|
@@ -63,7 +63,8 @@ export DEBEMAIL="soren@openstack.org"
|
|||||||
|
|
||||||
buildno=$BUILD_NUMBER
|
buildno=$BUILD_NUMBER
|
||||||
pkgversion="${version}-0ubuntu0~${series}${buildno}"
|
pkgversion="${version}-0ubuntu0~${series}${buildno}"
|
||||||
dch -b --force-distribution --v "${pkgversion}" "Automated PPA build. Packaging revision: ${PACKAGING_REVNO}." -D $series
|
dch -b --force-distribution --v "${pkgversion}" \
|
||||||
|
"Automated PPA build. Packaging revision: ${PACKAGING_REVNO}." -D $series
|
||||||
dpkg-buildpackage -rfakeroot -S -sa -nc -k32EE128C
|
dpkg-buildpackage -rfakeroot -S -sa -nc -k32EE128C
|
||||||
if ! [ "$DO_UPLOAD" = "no" ]; then
|
if ! [ "$DO_UPLOAD" = "no" ]; then
|
||||||
for ppa in $PPAS; do
|
for ppa in $PPAS; do
|
||||||
|
@@ -30,7 +30,9 @@ while ! grep -q "$END_UUID" /tmp/console.html; do
|
|||||||
# fails. This allows us to retry when we have Jenkins proxy
|
# fails. This allows us to retry when we have Jenkins proxy
|
||||||
# errors without polluting the output document.
|
# errors without polluting the output document.
|
||||||
# --insecure because our Jenkins masters use self signed SSL certs.
|
# --insecure because our Jenkins masters use self signed SSL certs.
|
||||||
curl -X POST --data "start=$(stat -c %s /tmp/console.html || echo 0)" --fail --insecure $BUILD_URL$console_log_path >> /tmp/console.html || true
|
curl -X POST --data "start=$(stat -c %s /tmp/console.html || echo 0)" \
|
||||||
|
--fail --insecure $BUILD_URL$console_log_path \
|
||||||
|
>> /tmp/console.html || true
|
||||||
done
|
done
|
||||||
|
|
||||||
# We need to add <pre> tags around the output for log-osanalyze to not escape
|
# We need to add <pre> tags around the output for log-osanalyze to not escape
|
||||||
|
@@ -36,11 +36,13 @@ JENKINSCI_REPO_CREDS="/home/jenkins/.jenkinsci-curl"
|
|||||||
curl -X PUT \
|
curl -X PUT \
|
||||||
--config ${JENKINSCI_REPO_CREDS} \
|
--config ${JENKINSCI_REPO_CREDS} \
|
||||||
--data-binary @${META_DATA_FILE} \
|
--data-binary @${META_DATA_FILE} \
|
||||||
-i "${JENKINSCI_REPO}/${PROJECT}/${VERSION}/${META_DATA_FILE}" > /dev/null 2>&1
|
-i "${JENKINSCI_REPO}/${PROJECT}/${VERSION}/${META_DATA_FILE}" \
|
||||||
|
> /dev/null 2>&1
|
||||||
|
|
||||||
curl -X PUT \
|
curl -X PUT \
|
||||||
--config ${JENKINSCI_REPO_CREDS} \
|
--config ${JENKINSCI_REPO_CREDS} \
|
||||||
--data-binary @${PLUGIN_FILE} \
|
--data-binary @${PLUGIN_FILE} \
|
||||||
-i "${JENKINSCI_REPO}/${PROJECT}/${VERSION}/${PLUGIN_FILE}" > /dev/null 2>&1
|
-i "${JENKINSCI_REPO}/${PROJECT}/${VERSION}/${PLUGIN_FILE}" \
|
||||||
|
> /dev/null 2>&1
|
||||||
|
|
||||||
exit $?
|
exit $?
|
||||||
|
@@ -20,7 +20,8 @@ source /etc/nodepool/provider
|
|||||||
|
|
||||||
NODEPOOL_PYPI_MIRROR=${NODEPOOL_PYPI_MIRROR:-http://pypi.$NODEPOOL_REGION.openstack.org/simple}
|
NODEPOOL_PYPI_MIRROR=${NODEPOOL_PYPI_MIRROR:-http://pypi.$NODEPOOL_REGION.openstack.org/simple}
|
||||||
|
|
||||||
sudo sed -i -e "s,^index-url = .*,index-url = $NODEPOOL_PYPI_MIRROR," /etc/pip.conf
|
sudo sed -i -e "s,^index-url = .*,index-url = $NODEPOOL_PYPI_MIRROR," \
|
||||||
|
/etc/pip.conf
|
||||||
|
|
||||||
cat >/home/jenkins/.pydistutils.cfg <<EOF
|
cat >/home/jenkins/.pydistutils.cfg <<EOF
|
||||||
[easy_install]
|
[easy_install]
|
||||||
|
@@ -97,7 +97,8 @@ function main {
|
|||||||
download_appliance "$STAGING_APPLIANCE_URL"
|
download_appliance "$STAGING_APPLIANCE_URL"
|
||||||
create_ramdisk_contents /root/xenserver.iso
|
create_ramdisk_contents /root/xenserver.iso
|
||||||
extract_xs_installer /root/xenserver.iso /opt/xs-install
|
extract_xs_installer /root/xenserver.iso /opt/xs-install
|
||||||
generate_xs_installer_grub_config /opt/xs-install file:///tmp/ramdisk/answerfile.xml
|
generate_xs_installer_grub_config /opt/xs-install \
|
||||||
|
file:///tmp/ramdisk/answerfile.xml
|
||||||
configure_grub
|
configure_grub
|
||||||
update-grub
|
update-grub
|
||||||
create_resizing_initramfs_config
|
create_resizing_initramfs_config
|
||||||
@@ -321,7 +322,8 @@ EOF
|
|||||||
|
|
||||||
function configure_grub {
|
function configure_grub {
|
||||||
sed -ie 's/^GRUB_HIDDEN_TIMEOUT/#GRUB_HIDDEN_TIMEOUT/g' /etc/default/grub
|
sed -ie 's/^GRUB_HIDDEN_TIMEOUT/#GRUB_HIDDEN_TIMEOUT/g' /etc/default/grub
|
||||||
sed -ie 's/^GRUB_HIDDEN_TIMEOUT_QUIET/#GRUB_HIDDEN_TIMEOUT_QUIET/g' /etc/default/grub
|
sed -ie 's/^GRUB_HIDDEN_TIMEOUT_QUIET/#GRUB_HIDDEN_TIMEOUT_QUIET/g' \
|
||||||
|
/etc/default/grub
|
||||||
# sed -ie 's/^GRUB_TIMEOUT=.*$/GRUB_TIMEOUT=-1/g' /etc/default/grub
|
# sed -ie 's/^GRUB_TIMEOUT=.*$/GRUB_TIMEOUT=-1/g' /etc/default/grub
|
||||||
sed -ie 's/^.*GRUB_TERMINAL=.*$/GRUB_TERMINAL=console/g' /etc/default/grub
|
sed -ie 's/^.*GRUB_TERMINAL=.*$/GRUB_TERMINAL=console/g' /etc/default/grub
|
||||||
sed -ie 's/GRUB_DEFAULT=0/GRUB_DEFAULT=saved/g' /etc/default/grub
|
sed -ie 's/GRUB_DEFAULT=0/GRUB_DEFAULT=saved/g' /etc/default/grub
|
||||||
@@ -518,7 +520,8 @@ function configure_networking {
|
|||||||
|
|
||||||
# Create vifs for the appliance
|
# Create vifs for the appliance
|
||||||
xe vif-create vm-uuid=$VM network-uuid=$HOST_INT_NET device=0
|
xe vif-create vm-uuid=$VM network-uuid=$HOST_INT_NET device=0
|
||||||
xe vif-create vm-uuid=$VM network-uuid=$ORIGINAL_MGT_NET mac=$MACADDRESS device=1
|
xe vif-create vm-uuid=$VM network-uuid=$ORIGINAL_MGT_NET mac=$MACADDRESS \
|
||||||
|
device=1
|
||||||
xe vif-create vm-uuid=$VM network-uuid=$NEW_MGT_NET device=2
|
xe vif-create vm-uuid=$VM network-uuid=$NEW_MGT_NET device=2
|
||||||
|
|
||||||
xe vm-start uuid=$VM
|
xe vm-start uuid=$VM
|
||||||
@@ -536,7 +539,8 @@ function configure_networking {
|
|||||||
DOMID=$(xe vm-param-get param-name=dom-id uuid=$VM)
|
DOMID=$(xe vm-param-get param-name=dom-id uuid=$VM)
|
||||||
|
|
||||||
# Authenticate temporary key to appliance
|
# Authenticate temporary key to appliance
|
||||||
xenstore-write /local/domain/$DOMID/authorized_keys/$DOMZERO_USER "$(cat /root/dom0key.pub)"
|
xenstore-write /local/domain/$DOMID/authorized_keys/$DOMZERO_USER \
|
||||||
|
"$(cat /root/dom0key.pub)"
|
||||||
xenstore-chmod -u /local/domain/$DOMID/authorized_keys/$DOMZERO_USER r$DOMID
|
xenstore-chmod -u /local/domain/$DOMID/authorized_keys/$DOMZERO_USER r$DOMID
|
||||||
|
|
||||||
while ! echo "true" | bash_on_appliance; do
|
while ! echo "true" | bash_on_appliance; do
|
||||||
|
@@ -43,7 +43,8 @@ elif [ -f /usr/bin/apt-get ]; then
|
|||||||
sudo DEBIAN_FRONTEND=noninteractive apt-get \
|
sudo DEBIAN_FRONTEND=noninteractive apt-get \
|
||||||
--option "Dpkg::Options::=--force-confold" \
|
--option "Dpkg::Options::=--force-confold" \
|
||||||
--assume-yes install build-essential python-dev python3-dev \
|
--assume-yes install build-essential python-dev python3-dev \
|
||||||
python-software-properties linux-headers-virtual linux-headers-$(uname -r)
|
python-software-properties linux-headers-virtual \
|
||||||
|
linux-headers-$(uname -r)
|
||||||
fi
|
fi
|
||||||
else
|
else
|
||||||
echo "Unsupported distro."
|
echo "Unsupported distro."
|
||||||
|
@@ -27,10 +27,14 @@ sudo -u jenkins -i /opt/nodepool-scripts/prepare_devstack.sh "$HOSTNAME"
|
|||||||
|
|
||||||
# Setup venv and install deps for prepare_tempest_testrepository.py
|
# Setup venv and install deps for prepare_tempest_testrepository.py
|
||||||
sudo virtualenv -p python2 /opt/git/subunit2sql-env
|
sudo virtualenv -p python2 /opt/git/subunit2sql-env
|
||||||
sudo -H /opt/git/subunit2sql-env/bin/pip install -U testrepository subunit2sql PyMySQL
|
sudo -H /opt/git/subunit2sql-env/bin/pip install -U testrepository \
|
||||||
|
subunit2sql PyMySQL
|
||||||
|
|
||||||
# Pre-seed tempest testrepository with data from subunit2sql
|
# Pre-seed tempest testrepository with data from subunit2sql
|
||||||
sudo -i env PATH=/opt/git/subunit2sql-env/bin:$PATH /opt/git/subunit2sql-env/bin/python2 /opt/nodepool-scripts/prepare_tempest_testrepository.py $TEMPEST_DIR
|
sudo -i env PATH=/opt/git/subunit2sql-env/bin:$PATH \
|
||||||
|
/opt/git/subunit2sql-env/bin/python2 \
|
||||||
|
/opt/nodepool-scripts/prepare_tempest_testrepository.py \
|
||||||
|
$TEMPEST_DIR
|
||||||
|
|
||||||
sudo chown -R jenkins:jenkins $TEMPEST_DIR/preseed-streams
|
sudo chown -R jenkins:jenkins $TEMPEST_DIR/preseed-streams
|
||||||
|
|
||||||
|
@@ -22,6 +22,7 @@ export SUDO='true'
|
|||||||
export THIN='true'
|
export THIN='true'
|
||||||
|
|
||||||
./prepare_node.sh "$HOSTNAME"
|
./prepare_node.sh "$HOSTNAME"
|
||||||
sudo -u jenkins -i /opt/nodepool-scripts/prepare_devstack_virt_preview.sh "$HOSTNAME"
|
sudo -u jenkins -i /opt/nodepool-scripts/prepare_devstack_virt_preview.sh \
|
||||||
|
"$HOSTNAME"
|
||||||
|
|
||||||
./restrict_memory.sh
|
./restrict_memory.sh
|
||||||
|
@@ -19,7 +19,9 @@
|
|||||||
# cpu resources can be used without the risk of becoming dependent on more
|
# cpu resources can be used without the risk of becoming dependent on more
|
||||||
# memory.
|
# memory.
|
||||||
if [ -f /etc/default/grub ] ; then
|
if [ -f /etc/default/grub ] ; then
|
||||||
sudo sed -i -e 's/^GRUB_TIMEOUT=[0-9]\+/GRUB_TIMEOUT=0/' -e 's/#\?GRUB_CMDLINE_LINUX="/GRUB_CMDLINE_LINUX="mem=9023M /g' /etc/default/grub
|
sudo sed -i -e 's/^GRUB_TIMEOUT=[0-9]\+/GRUB_TIMEOUT=0/' \
|
||||||
|
-e 's/#\?GRUB_CMDLINE_LINUX="/GRUB_CMDLINE_LINUX="mem=9023M /g' \
|
||||||
|
/etc/default/grub
|
||||||
if which update-grub &> /dev/null ; then
|
if which update-grub &> /dev/null ; then
|
||||||
sudo update-grub
|
sudo update-grub
|
||||||
else
|
else
|
||||||
@@ -27,5 +29,6 @@ if [ -f /etc/default/grub ] ; then
|
|||||||
sudo /usr/sbin/grub2-mkconfig -o /boot/grub2/grub.cfg
|
sudo /usr/sbin/grub2-mkconfig -o /boot/grub2/grub.cfg
|
||||||
fi
|
fi
|
||||||
elif [ -f /boot/grub/grub.conf ] ; then
|
elif [ -f /boot/grub/grub.conf ] ; then
|
||||||
sudo sed -i -e 's/^timeout=[0-9]\+/timeout=0/' -e 's/\(^\s\+kernel.*\)/\1 mem=9023M/' /boot/grub/grub.conf
|
sudo sed -i -e 's/^timeout=[0-9]\+/timeout=0/' \
|
||||||
|
-e 's/\(^\s\+kernel.*\)/\1 mem=9023M/' /boot/grub/grub.conf
|
||||||
fi
|
fi
|
||||||
|
@@ -13,4 +13,7 @@
|
|||||||
# See the License for the specific language governing permissions and
|
# See the License for the specific language governing permissions and
|
||||||
# limitations under the License.
|
# limitations under the License.
|
||||||
|
|
||||||
docker.io run --privileged=true -v ~/.cache:/.cache -v $(git rev-parse --show-toplevel):/opt/system-config -w /opt/system-config -i -t openstack_infra/ubuntu /bin/bash tools/build-image.sh
|
docker.io run --privileged=true -v ~/.cache:/.cache -v \
|
||||||
|
$(git rev-parse --show-toplevel):/opt/system-config \
|
||||||
|
-w /opt/system-config -i -t openstack_infra/ubuntu \
|
||||||
|
/bin/bash tools/build-image.sh
|
||||||
|
@@ -1,4 +1,5 @@
|
|||||||
#!/bin/bash
|
#!/bin/bash
|
||||||
|
|
||||||
ROOT=$(readlink -fn $(dirname $0)/.. )
|
ROOT=$(readlink -fn $(dirname $0)/.. )
|
||||||
find $ROOT -not -wholename \*.tox/\* -and -not -wholename \*.test/\* -and -name \*.sh -print0 | xargs -0 bashate -v
|
find $ROOT -not -wholename \*.tox/\* -and -not -wholename \*.test/\* \
|
||||||
|
-and -name \*.sh -print0 | xargs -0 bashate -v
|
||||||
|
Reference in New Issue
Block a user