Skip to content

Commit

Permalink
update to ubuntu 14.04 and move the snapshot to Frankfurt 1
Browse files Browse the repository at this point in the history
  • Loading branch information
g-div committed Oct 12, 2015
1 parent 8623cb6 commit 1ae8ef4
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 12 deletions.
5 changes: 3 additions & 2 deletions build.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,16 +2,17 @@
"builders": [{
"type": "digitalocean",
"api_token": "",
"region": "ams3",
"region": "fra1",
"image": "ubuntu-14-04-x64",
"size": "512mb",
"snapshot_name": "nginx-nvm-mongo-{{timestamp}}"
}],

"provisioners": [{
"type": "shell",
"inline": [
"sleep 30",
"DEBIAN_FRONTEND=noninteractive",
"apt-get update",
"apt-get install -y software-properties-common python-software-properties",
"add-apt-repository -y ppa:rquillo/ansible",
"apt-get update",
Expand Down
11 changes: 1 addition & 10 deletions run.sh
Original file line number Diff line number Diff line change
Expand Up @@ -5,20 +5,11 @@ PACKER_BIN="packer-io"
PACKER_BUILD="build.json"
SSH_PUB_KEY="$HOME/.ssh/id_rsa.pub"

BASEDIR=$(dirname $0)

cat $SSH_PUB_KEY > $BASEDIR/ansible/files/id_rsa.pub

# This script will delete all symlinks in this folder.
# Ir's a quickfix for the following bug:
# https://github.com/mitchellh/packer/issues/1627
cd $BASEDIR
find -type l -delete
cat $SSH_PUB_KEY > ./ansible/files/id_rsa.pub

$PACKER_BIN validate $PACKER_BUILD
$PACKER_BIN build $PACKER_BUILD

unset PACKER_BIN
unset PACKER_BUILD
unset BASEDIR
unset SSH_PUB_KEY

0 comments on commit 1ae8ef4

Please sign in to comment.