Skip to content

Instantly share code, notes, and snippets.

@wacko
Created May 30, 2013 13:29
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save wacko/5677809 to your computer and use it in GitHub Desktop.
Save wacko/5677809 to your computer and use it in GitHub Desktop.
sudo apt-get -y install python-software-properties
sudo add-apt-repository ppa:juju/pkgs
sudo apt-get update
sudo apt-get -y install lxc apt-cacher-ng libzookeeper-java zookeeper juju git
# create a SSH authorized/public key
ssh-keygen -t rsa
# set AWS credentials
export AWS_ACCESS_KEY_ID=XXXXXXXX
export AWS_SECRET_ACCESS_KEY=YYYYYYYY
# edit `~/.juju/environments.yaml` (if it doesn't exists, run `juju bootstrap` to create it and ignore the error you'll get)
# add `type: local` and `data-dir`
environments:
cf-test:
type: local
control-bucket: juju-a14dfae3830142d9ac23c499315c2785998
admin-secret: 6608267bbd6b447b8c90934167b1a294998
data-dir: /home/your_user/some_dir
default-series: precise
access-key: XXXXXXXX
secret-key: YYYYYYYY
juju bootstrap
juju status # => running
@wacko
Copy link
Author

wacko commented May 30, 2013

For local deployment:

environments:
  cf-test:
    type: local
    control-bucket: juju-a14dfae3830142d9ac23c499315c2785998
    admin-secret: 6608267bbd6b447b8c90934167b1a294998
    data-dir: /home/your_user/some_dir
    default-series: precise

To deploy on AWS:

environments:
  cf-test:
    type: ec2
    control-bucket: juju-a14dfae3830142d9ac23c499315c2785998
    admin-secret: 6608267bbd6b447b8c90934167b1a294998
    default-series: precise
    access-key: XXXXXXXX
    secret-key: YYYYYYYY

Or you can create two different environments on the same file (cf-local & cf-amazon) and set the environment as an argument:

juju bootstrap --environment ENVIRONMENT

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment