Skip to content
This repository has been archived by the owner on Nov 30, 2021. It is now read-only.

Commit

Permalink
added nova client fo uploading SSH keys
Browse files Browse the repository at this point in the history
  • Loading branch information
Matthew Fisher committed Mar 7, 2014
1 parent 7de5caf commit 9019f0d
Showing 1 changed file with 6 additions and 4 deletions.
10 changes: 6 additions & 4 deletions contrib/rackspace/provision-rackspace-controller.sh
Original file line number Diff line number Diff line change
Expand Up @@ -21,9 +21,8 @@ if ! "$CONTRIB_DIR/check-deis-deps.sh"; then
exit 1
fi

# check for knife-rackspace
if ! knife rackspace server list > /dev/null; then
echo 'Please install the knife-rackspace Ruby gem and configure knife.rb.'
if ! nova --version > /dev/null 2>&1; then
echo "Please install nova using 'pip install python-novaclient'."
exit 1
fi

Expand Down Expand Up @@ -74,7 +73,10 @@ fi

# upload the user's SSH key to Rackspace.
# if it fails, that means that it's already been uploaded.
nova keypair-add --pub-key $ssh_key_path.pub deis > /dev/null 2>&1
echo "uploading keypair to Rackspace, please wait"
if ! nova keypair-add --pub-key $ssh_key_path.pub deis > /dev/null; then
echo "keypair already uploaded to Rackspace. Skipping."
fi

# create data bags
knife data bag create deis-formations 2>/dev/null
Expand Down

0 comments on commit 9019f0d

Please sign in to comment.