Skip to content

Commit c7f72ad

Browse files
committed
should speed up by 20 seconds - sudo and no sleep
1 parent 00d6bc6 commit c7f72ad

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

stack.sh

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -103,8 +103,7 @@ if [[ $EUID -eq 0 ]]; then
103103

104104
# since this script runs as a normal user, we need to give that user
105105
# ability to run sudo
106-
apt_get update
107-
apt_get install sudo
106+
dpkg -l sudo || apt_get update && apt_get install sudo
108107

109108
if ! getent passwd stack >/dev/null; then
110109
echo "Creating a user called stack"

tools/build_uec.sh

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -171,13 +171,14 @@ EOF
171171
cat > $vm_dir/uec/user-data<<EOF
172172
#!/bin/bash
173173
apt-get update
174-
apt-get install git -y
174+
apt-get install git sudo -y
175175
git clone https://github.com/cloudbuilders/devstack.git
176176
cd devstack
177177
git remote set-url origin `cd $TOP_DIR; git remote show origin | grep Fetch | awk '{print $3}'`
178178
git fetch
179179
git checkout `git rev-parse HEAD`
180180
cat > localrc <<LOCAL_EOF
181+
ROOTSLEEP=0
181182
`cat $TOP_DIR/localrc`
182183
LOCAL_EOF
183184
./stack.sh

0 commit comments

Comments
 (0)