Merge "Cleanup tools scripts"
This commit is contained in:
commit
e76fb89bbf
@ -1,4 +1,7 @@
|
|||||||
#!/usr/bin/env bash
|
#!/usr/bin/env bash
|
||||||
|
|
||||||
|
# **build_bm.sh**
|
||||||
|
|
||||||
# Build an OpenStack install on a bare metal machine.
|
# Build an OpenStack install on a bare metal machine.
|
||||||
set +x
|
set +x
|
||||||
|
|
||||||
|
@ -1,4 +1,7 @@
|
|||||||
#!/usr/bin/env bash
|
#!/usr/bin/env bash
|
||||||
|
|
||||||
|
# **build_bm_multi.sh**
|
||||||
|
|
||||||
# Build an OpenStack install on several bare metal machines.
|
# Build an OpenStack install on several bare metal machines.
|
||||||
SHELL_AFTER_RUN=no
|
SHELL_AFTER_RUN=no
|
||||||
|
|
||||||
|
@ -1,5 +1,8 @@
|
|||||||
#!/bin/bash -e
|
#!/bin/bash -e
|
||||||
# build_pxe_env.sh - Create a PXE boot environment
|
|
||||||
|
# **build_pxe_env.sh**
|
||||||
|
|
||||||
|
# Create a PXE boot environment
|
||||||
#
|
#
|
||||||
# build_pxe_env.sh destdir
|
# build_pxe_env.sh destdir
|
||||||
#
|
#
|
||||||
|
@ -1,7 +1,10 @@
|
|||||||
#!/bin/bash
|
#!/bin/bash
|
||||||
# build_ramdisk.sh - Build RAM disk images
|
|
||||||
|
|
||||||
# exit on error to stop unexpected errors
|
# **build_ramdisk.sh**
|
||||||
|
|
||||||
|
# Build RAM disk images
|
||||||
|
|
||||||
|
# Exit on error to stop unexpected errors
|
||||||
set -o errexit
|
set -o errexit
|
||||||
|
|
||||||
if [ ! "$#" -eq "1" ]; then
|
if [ ! "$#" -eq "1" ]; then
|
||||||
@ -84,7 +87,7 @@ fi
|
|||||||
# Finds the next available NBD device
|
# Finds the next available NBD device
|
||||||
# Exits script if error connecting or none free
|
# Exits script if error connecting or none free
|
||||||
# map_nbd image
|
# map_nbd image
|
||||||
# returns full nbd device path
|
# Returns full nbd device path
|
||||||
function map_nbd {
|
function map_nbd {
|
||||||
for i in `seq 0 15`; do
|
for i in `seq 0 15`; do
|
||||||
if [ ! -e /sys/block/nbd$i/pid ]; then
|
if [ ! -e /sys/block/nbd$i/pid ]; then
|
||||||
@ -105,7 +108,7 @@ function map_nbd {
|
|||||||
echo $NBD
|
echo $NBD
|
||||||
}
|
}
|
||||||
|
|
||||||
# prime image with as many apt/pips as we can
|
# Prime image with as many apt/pips as we can
|
||||||
DEV_FILE=$CACHEDIR/$DIST_NAME-dev.img
|
DEV_FILE=$CACHEDIR/$DIST_NAME-dev.img
|
||||||
DEV_FILE_TMP=`mktemp $DEV_FILE.XXXXXX`
|
DEV_FILE_TMP=`mktemp $DEV_FILE.XXXXXX`
|
||||||
if [ ! -r $DEV_FILE ]; then
|
if [ ! -r $DEV_FILE ]; then
|
||||||
@ -127,11 +130,11 @@ if [ ! -r $DEV_FILE ]; then
|
|||||||
mkdir -p $MNTDIR/$DEST
|
mkdir -p $MNTDIR/$DEST
|
||||||
chroot $MNTDIR chown stack $DEST
|
chroot $MNTDIR chown stack $DEST
|
||||||
|
|
||||||
# a simple password - pass
|
# A simple password - pass
|
||||||
echo stack:pass | chroot $MNTDIR chpasswd
|
echo stack:pass | chroot $MNTDIR chpasswd
|
||||||
echo root:$ROOT_PASSWORD | chroot $MNTDIR chpasswd
|
echo root:$ROOT_PASSWORD | chroot $MNTDIR chpasswd
|
||||||
|
|
||||||
# and has sudo ability (in the future this should be limited to only what
|
# And has sudo ability (in the future this should be limited to only what
|
||||||
# stack requires)
|
# stack requires)
|
||||||
echo "stack ALL=(ALL) NOPASSWD: ALL" >> $MNTDIR/etc/sudoers
|
echo "stack ALL=(ALL) NOPASSWD: ALL" >> $MNTDIR/etc/sudoers
|
||||||
|
|
||||||
@ -143,7 +146,8 @@ if [ ! -r $DEV_FILE ]; then
|
|||||||
fi
|
fi
|
||||||
rm -f $DEV_FILE_TMP
|
rm -f $DEV_FILE_TMP
|
||||||
|
|
||||||
# clone git repositories onto the system
|
|
||||||
|
# Clone git repositories onto the system
|
||||||
# ======================================
|
# ======================================
|
||||||
|
|
||||||
IMG_FILE_TMP=`mktemp $IMG_FILE.XXXXXX`
|
IMG_FILE_TMP=`mktemp $IMG_FILE.XXXXXX`
|
||||||
|
@ -1,7 +1,8 @@
|
|||||||
#!/usr/bin/env bash
|
#!/usr/bin/env bash
|
||||||
#
|
#
|
||||||
# build_tempest.sh - Checkout and prepare a Tempest repo
|
# **build_tempest.sh**
|
||||||
# (https://github.com/openstack/tempest.git)
|
|
||||||
|
# Checkout and prepare a Tempest repo: https://github.com/openstack/tempest.git
|
||||||
|
|
||||||
function usage {
|
function usage {
|
||||||
echo "$0 - Check out and prepare a Tempest repo"
|
echo "$0 - Check out and prepare a Tempest repo"
|
||||||
|
@ -1,5 +1,7 @@
|
|||||||
#!/usr/bin/env bash
|
#!/usr/bin/env bash
|
||||||
|
|
||||||
|
# **build_uec.sh**
|
||||||
|
|
||||||
# Make sure that we have the proper version of ubuntu (only works on oneiric)
|
# Make sure that we have the proper version of ubuntu (only works on oneiric)
|
||||||
if ! egrep -q "oneiric" /etc/lsb-release; then
|
if ! egrep -q "oneiric" /etc/lsb-release; then
|
||||||
echo "This script only works with ubuntu oneiric."
|
echo "This script only works with ubuntu oneiric."
|
||||||
|
@ -1,7 +1,10 @@
|
|||||||
#!/usr/bin/env bash
|
#!/usr/bin/env bash
|
||||||
# build_uec_ramdisk.sh - Build RAM disk images based on UEC image
|
|
||||||
|
|
||||||
# exit on error to stop unexpected errors
|
# **build_uec_ramdisk.sh**
|
||||||
|
|
||||||
|
# Build RAM disk images based on UEC image
|
||||||
|
|
||||||
|
# Exit on error to stop unexpected errors
|
||||||
set -o errexit
|
set -o errexit
|
||||||
|
|
||||||
if [ ! "$#" -eq "1" ]; then
|
if [ ! "$#" -eq "1" ]; then
|
||||||
@ -58,7 +61,7 @@ DIST_NAME=${DIST_NAME:-oneiric}
|
|||||||
# Configure how large the VM should be
|
# Configure how large the VM should be
|
||||||
GUEST_SIZE=${GUEST_SIZE:-2G}
|
GUEST_SIZE=${GUEST_SIZE:-2G}
|
||||||
|
|
||||||
# exit on error to stop unexpected errors
|
# Exit on error to stop unexpected errors
|
||||||
set -o errexit
|
set -o errexit
|
||||||
set -o xtrace
|
set -o xtrace
|
||||||
|
|
||||||
|
@ -1,5 +1,8 @@
|
|||||||
#!/bin/bash -e
|
#!/bin/bash -e
|
||||||
# build_usb_boot.sh - Create a syslinux boot environment
|
|
||||||
|
# **build_usb_boot.sh**
|
||||||
|
|
||||||
|
# Create a syslinux boot environment
|
||||||
#
|
#
|
||||||
# build_usb_boot.sh destdev
|
# build_usb_boot.sh destdev
|
||||||
#
|
#
|
||||||
|
@ -1,6 +1,8 @@
|
|||||||
#!/usr/bin/env bash
|
#!/usr/bin/env bash
|
||||||
#
|
#
|
||||||
# configure_tempest.sh - Build a tempest configuration file from devstack
|
# **configure_tempest.sh**
|
||||||
|
|
||||||
|
# Build a tempest configuration file from devstack
|
||||||
|
|
||||||
echo "**************************************************"
|
echo "**************************************************"
|
||||||
echo "Configuring Tempest"
|
echo "Configuring Tempest"
|
||||||
|
@ -1,5 +1,7 @@
|
|||||||
#!/usr/bin/env bash
|
#!/usr/bin/env bash
|
||||||
|
|
||||||
|
# **copy_dev_environment_to_uec.sh**
|
||||||
|
|
||||||
# Echo commands
|
# Echo commands
|
||||||
set -o xtrace
|
set -o xtrace
|
||||||
|
|
||||||
|
@ -1,5 +1,8 @@
|
|||||||
#!/bin/bash
|
#!/bin/bash
|
||||||
# get_uec_image.sh - Prepare Ubuntu UEC images
|
|
||||||
|
# **get_uec_image.sh**
|
||||||
|
|
||||||
|
# Download and prepare Ubuntu UEC images
|
||||||
|
|
||||||
CACHEDIR=${CACHEDIR:-/opt/stack/cache}
|
CACHEDIR=${CACHEDIR:-/opt/stack/cache}
|
||||||
ROOTSIZE=${ROOTSIZE:-2000}
|
ROOTSIZE=${ROOTSIZE:-2000}
|
||||||
@ -11,12 +14,12 @@ TOP_DIR=$(cd $TOOLS_DIR/..; pwd)
|
|||||||
# Import common functions
|
# Import common functions
|
||||||
. $TOP_DIR/functions
|
. $TOP_DIR/functions
|
||||||
|
|
||||||
# exit on error to stop unexpected errors
|
# Exit on error to stop unexpected errors
|
||||||
set -o errexit
|
set -o errexit
|
||||||
set -o xtrace
|
set -o xtrace
|
||||||
|
|
||||||
usage() {
|
usage() {
|
||||||
echo "Usage: $0 - Fetch and prepare Ubuntu images"
|
echo "Usage: $0 - Download and prepare Ubuntu UEC images"
|
||||||
echo ""
|
echo ""
|
||||||
echo "$0 [-r rootsize] release imagefile [kernel]"
|
echo "$0 [-r rootsize] release imagefile [kernel]"
|
||||||
echo ""
|
echo ""
|
||||||
|
@ -1,5 +1,8 @@
|
|||||||
#!/usr/bin/env bash
|
#!/usr/bin/env bash
|
||||||
# info.sh - Produce a report on the state of devstack installs
|
|
||||||
|
# **info.sh**
|
||||||
|
|
||||||
|
# Produce a report on the state of devstack installs
|
||||||
#
|
#
|
||||||
# Output fields are separated with '|' chars
|
# Output fields are separated with '|' chars
|
||||||
# Output types are git,localrc,os,pip,pkg:
|
# Output types are git,localrc,os,pip,pkg:
|
||||||
|
@ -1,5 +1,8 @@
|
|||||||
#!/bin/bash
|
#!/bin/bash
|
||||||
# install_openvpn.sh - Install OpenVPN and generate required certificates
|
|
||||||
|
# **install_openvpn.sh**
|
||||||
|
|
||||||
|
# Install OpenVPN and generate required certificates
|
||||||
#
|
#
|
||||||
# install_openvpn.sh --client name
|
# install_openvpn.sh --client name
|
||||||
# install_openvpn.sh --server [name]
|
# install_openvpn.sh --server [name]
|
||||||
|
@ -1,5 +1,7 @@
|
|||||||
#!/usr/bin/env bash
|
#!/usr/bin/env bash
|
||||||
|
|
||||||
|
# **warm_apts_and_pips_for_uec.sh**
|
||||||
|
|
||||||
# Echo commands
|
# Echo commands
|
||||||
set -o xtrace
|
set -o xtrace
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user