move screenrc from stack.sh

This commit is contained in:
Jesse Andrews 2011-09-11 16:34:34 -07:00
parent f2ef760caa
commit 5f0982007f
5 changed files with 20 additions and 18 deletions

1
.gitignore vendored Normal file
View file

@ -0,0 +1 @@
proto

View file

@ -11,7 +11,7 @@ rm -rf $DEST
# build a proto image - natty + packages that will install (optimization) # build a proto image - natty + packages that will install (optimization)
if [ ! -d proto ]; then if [ ! -d proto ]; then
debootstrap natty proto debootstrap natty proto
cp sources.list proto/etc/apt/sources.list cp files/sources.list proto/etc/apt/sources.list
chroot proto apt-get update chroot proto apt-get update
chroot proto apt-get install -y `cat apts/* | cut -d\# -f1 | egrep -v "(rabbitmq|libvirt-bin)"` chroot proto apt-get install -y `cat apts/* | cut -d\# -f1 | egrep -v "(rabbitmq|libvirt-bin)"`
chroot proto pip install `cat pips/*` chroot proto pip install `cat pips/*`
@ -33,17 +33,21 @@ echo "127.0.0.1 localhost $NAME" > $DEST/etc/hosts
# copy kernel modules # copy kernel modules
cp -pr /lib/modules/`uname -r` $DEST/lib/modules cp -pr /lib/modules/`uname -r` $DEST/lib/modules
# helpful screenrc
cp files/screenrc $DEST/root/.screenrc
# copy openstack installer and requirement lists to a new directory. # copy openstack installer and requirement lists to a new directory.
mkdir -p $DEST/opt mkdir -p $DEST/opt
cp stack.sh $DEST/opt/stack.sh cp stack.sh $DEST/opt/stack.sh
cp -r pips $DEST/opt cp -r pips $DEST/opt
cp -r apts $DEST/opt cp -r apts $DEST/opt
# injecting root's ssh key # injecting root's public ssh key if it exists
# FIXME: only do this if id_rsa.pub exists if [ -f /root/.ssh/id_rsa.pub ]; then
mkdir $DEST/root/.ssh mkdir $DEST/root/.ssh
chmod 700 $DEST/root/.ssh chmod 700 $DEST/root/.ssh
cp /root/.ssh/id_rsa.pub $DEST/root/.ssh/authorized_keys cp /root/.ssh/id_rsa.pub $DEST/root/.ssh/authorized_keys
fi
# set root password to password # set root password to password
echo root:password | chroot $DEST chpasswd echo root:password | chroot $DEST chpasswd

9
files/screenrc Normal file
View file

@ -0,0 +1,9 @@
hardstatus on
hardstatus alwayslastline
hardstatus string "%{.bW}%-w%{.rW}%n %t%{-}%+w %=%{..G}%H %{..Y}%d/%m %c"
defscrollback 1024
vbell off
startup_message off

View file

@ -133,18 +133,6 @@ EOF
exit exit
fi fi
# Configure screen
cat >~/.screenrc <<EOF
hardstatus on
hardstatus alwayslastline
hardstatus string "%{.bW}%-w%{.rW}%n %t%{-}%+w %=%{..G}%H %{..Y}%d/%m %c"
defscrollback 1024
vbell off
startup_message off
EOF
NL=`echo -ne '\015'` NL=`echo -ne '\015'`
function screen_it { function screen_it {