Skip to content

Commit 1d1c661

Browse files
committed
Clean up /etc/chef and install inotify-tools across all providers.
1 parent 0e768b8 commit 1d1c661

4 files changed

Lines changed: 13 additions & 16 deletions

File tree

contrib/digitalocean/prepare-digitalocean-snapshot.sh

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,7 @@ apt-get update
4646
apt-get -qy upgrade
4747

4848
# install required packages
49-
apt-get install lxc-docker-0.7.6 curl git make python-setuptools python-pip -yq
49+
apt-get install lxc-docker-0.7.6 curl git inotify-tools make python-setuptools python-pip -yq
5050

5151
# wait for docker to start
5252
while [ ! -e /var/run/docker.sock ] ; do
@@ -71,8 +71,9 @@ rm -rf /var/lib/cloud
7171
# purge SSH authorized keys
7272
rm -f /root/.ssh/authorized_keys
7373

74-
# ssh host keys are automatically regenerated
75-
# on system boot by ubuntu cloud init
74+
# remove /etc/chef so contents can't intefere with
75+
# node being converged (i.e. old keys)
76+
rm -f /etc/chef/*
7677

7778
# purge /var/log
7879
find /var/log -type f | xargs rm

contrib/ec2/prepare-ubuntu-ami.sh

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,7 @@ apt-get update
3939
apt-get dist-upgrade -yq
4040

4141
# install required packages
42-
apt-get install lxc-docker-0.7.6 curl git make python-setuptools python-pip -yq
42+
apt-get install lxc-docker-0.7.6 curl git inotify-tools make python-setuptools python-pip -yq
4343

4444
# wait for docker to start
4545
while [ ! -e /var/run/docker.sock ] ; do
@@ -65,8 +65,9 @@ rm -rf /var/lib/cloud
6565
rm -f /home/ubuntu/.ssh/authorized_keys
6666
rm -f /root/.ssh/authorized_keys
6767

68-
# ssh host keys are automatically regenerated
69-
# on system boot by ubuntu cloud init
68+
# remove /etc/chef so contents can't intefere with
69+
# node being converged (i.e. old keys)
70+
rm -f /etc/chef/*
7071

7172
# purge /var/log
7273
find /var/log -type f | xargs rm

contrib/rackspace/prepare-rackspace-image.sh

Lines changed: 1 addition & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@ apt-get update
4040
apt-get dist-upgrade -yq
4141

4242
# install required packages
43-
apt-get install lxc-docker-0.7.6 curl git make python-setuptools python-pip -yq
43+
apt-get install lxc-docker-0.7.6 curl git inotify-tools make python-setuptools python-pip -yq
4444

4545
# wait for docker to start
4646
while [ ! -e /var/run/docker.sock ] ; do
@@ -66,18 +66,12 @@ rm -rf /var/lib/cloud
6666
rm -f /home/ubuntu/.ssh/authorized_keys
6767
rm -f /root/.ssh/authorized_keys
6868

69-
# ssh host keys are automatically regenerated
70-
# on system boot by ubuntu cloud init
71-
7269
# remove /etc/chef so contents can't intefere with
7370
# node being converged (i.e. old keys)
7471
rm -f /etc/chef/*
7572

7673
# purge /var/log
7774
find /var/log -type f | xargs rm
7875

79-
# Sync call needs this package
80-
apt-get -yqq install inotify-tools
81-
8276
# flush writes to block storage
8377
sync

contrib/vagrant/prepare-ubuntu-box.sh

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@ apt-get update
4242
apt-get dist-upgrade -yq
4343

4444
# install required packages
45-
apt-get install lxc-docker-0.7.6 git make python-setuptools python-pip -yq
45+
apt-get install lxc-docker-0.7.6 git inotify-tools make python-setuptools python-pip -yq
4646

4747
# wait for docker to start
4848
while [ ! -e /var/run/docker.sock ] ; do
@@ -71,8 +71,9 @@ rm -rf /var/lib/cloud
7171
# rm -f /home/ubuntu/.ssh/authorized_keys
7272
rm -f /root/.ssh/authorized_keys
7373

74-
# ssh host keys are automatically regenerated
75-
# on system boot by ubuntu cloud init
74+
# remove /etc/chef so contents can't intefere with
75+
# node being converged (i.e. old keys)
76+
rm -f /etc/chef/*
7677

7778
# purge /var/log
7879
find /var/log -type f | xargs rm

0 commit comments

Comments
 (0)