Take the 2-minute tour ×
Ask Ubuntu is a question and answer site for Ubuntu users and developers. It's 100% free, no registration required.

I've fired up some of the example instances of Wordpress and MySQL with Juju. A coworker has told me that the default instance size is "small". I'd like to be able to scale this to different sizes on Amazon EC2.

How can I adjust this, is this something defined in a formula or is it an argument I can pass Juju on the command line?

Let's say for example I wanted to deploy wordpress on "large" amazon instances.

share|improve this question

2 Answers 2

up vote 7 down vote accepted

As per this section of the documentation you need to define the instance-type as part of a machine constraint:

Deploy MySQL on a machine with at least 32GiB of RAM, and at least 8 ECU of CPU power (architecture will be inherited from the environment, or default to amd64):

juju deploy --constraints "cpu-cores=8 mem=32G" mysql

Deploy to t1.micros on AWS:

juju bootstrap --constraints "cpu-power=0 mem=512M"

Launch all future "mysql" machines with at least 8GiB of RAM and 4 ECU:

juju set-constraints --service mysql mem=8G cpu-cores=4
share|improve this answer

There is one caveat about setting this on the environment namely that if your using an image which needs a 64-bit image, you'll need to specify the ami directly with default-instance-id.

We're currently working on a more generic resource constraint implementation which will be significantly more flexible and cross provider.

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.