SpamapS.org – Full Frontal Nerdity

Clint Byrum's Personal Stuff

Juju constraints unbinds your machines »« Precise is coming

Configurate your juju’s

I was reading Jorge’s Stomp Box earlier today, and somebody mentioned how it would be an even better trick if it were easier to configure juju quickly.

Ask and ye shall receive. I hacked a new sub-command into the experimental ‘juju-jitsu’ wrapper. I’ll let the scrape from my terminal do the talking. You can get it with:


bzr branch lp:juju-jitsu

And try it with


juju-jitsu/wrap-juju
juju setup-environment

clint@clint-MacBookPro:~/src/juju-jitsu/juju-jitsu$ ./wrap-juju
Aliasing juju to /home/clint/src/juju-jitsu/juju-jitsu/juju-jitsu-wrapper...
(juju-jitsu) clint@clint-MacBookPro:~/src/juju-jitsu/juju-jitsu$ juju setup-environment
Name for environment name : mybox
What provider do you want to use? (ec2,local) type [local]:
Default "series", a.k.a. release codename of Ubunt default-series [precise]:
local dir to store logs/directory structure/charm data-dir [~/.juju/data]:
environments:
mybox:
data-dir: ~/.juju/data
default-series: precise
type: local

Do you want to

[s]ave this to /home/clint/.juju/environments.yaml
[d]iff with existing /home/clint/.juju/environments.yaml
[q]uit

[sdq]: d
diff: /home/clint/.juju/environments.yaml: No such file or directory
[sdq]: s
(juju-jitsu) clint@clint-MacBookPro:~/src/juju-jitsu/juju-jitsu$ cat ~/.juju/environments.yaml
environments:
mybox:
data-dir: ~/.juju/data
default-series: precise
type: local
(juju-jitsu) clint@clint-MacBookPro:~/src/juju-jitsu/juju-jitsu$ juju setup-environment
Name for environment name : mycloud
What provider do you want to use? (ec2,local) type [local]: ec2
Default "series", a.k.a. release codename of Ubunt default-series [precise]:
S3 Bucket to store data in control-bucket [juju-jitsu-D8mzlogDmvPjTpASolJnXK6HxwAW8YA8]:
Zookeeper Secret admin-secret [qUJIUiwji-jiAN-XTSC1ztxUrm2XrYys]:
(AWS_ACCESS_KEY_ID) access-key [XXXXXXXXXXXXXXXXXXXX]:
(AWS_SECRET_ACCESS_KEY) secret-key [xYxYxYxYxYxYxYxYxYxY/WvWvWvWvWvWv]:
Default Instance Type (m1.small, c1.medium, etc default-instance-type :
Default AMI default-image-id :
EC2 Region region :
EC2 URI ec2-uri :
S3 URI s3-uri :
environments:
mybox:
data-dir: ~/.juju/data
default-series: precise
type: local
mycloud:
access-key: XXXXXXXXXXXXXXXXXXXX
admin-secret: qUJIUiwji-jiAN-XTSC1ztxUrm2XrYys
control-bucket: juju-jitsu-D8mzlogDmvPjTpASolJnXK6HxwAW8YA8
default-series: precise
secret-key: xYxYxYxYxYxYxYxYxYxY/WvWvWvWvWvWv
type: ec2

Do you want to

[s]ave this to /home/clint/.juju/environments.yaml
[d]iff with existing /home/clint/.juju/environments.yaml
[q]uit

[sdq]:
[sdq]: d
--- /home/clint/.juju/environments.yaml 2012-03-15 16:36:47.939298045 -0700
+++ /home/clint/.juju/.environments.yaml.QqwCt_ 2012-03-15 16:37:20.629394484 -0700
@@ -3,3 +3,10 @@
data-dir: ~/.juju/data
default-series: precise
type: local
+ mycloud:
+ access-key: XXXXXXXXXXXXXXXXXXXX
+ admin-secret: qUJIUiwji-jiAN-XTSC1ztxUrm2XrYys
+ control-bucket: juju-jitsu-D8mzlogDmvPjTpASolJnXK6HxwAW8YA8
+ default-series: precise
+ secret-key: xYxYxYxYxYxYxYxYxYxY/WvWvWvWvWvWv
+ type: ec2
[sdq]: s
2012-03-15 16:37:23,799 juju-jitsu Backing up /home/clint/.juju/environments.yaml to /home/clint/.juju/environments.yaml.2
(juju-jitsu) clint@clint-MacBookPro:~/src/juju-jitsu/juju-jitsu$ bzr info
Repository tree (format: 2a)
Location:
shared repository: /home/clint/src/juju-jitsu
repository branch: .

Related branches:
push branch: bzr+ssh://bazaar.launchpad.net/+branch/juju-jitsu/
parent branch: bzr+ssh://bazaar.launchpad.net/+branch/juju-jitsu/
(juju-jitsu) clint@clint-MacBookPro:~/src/juju-jitsu/juju-jitsu$
March 15, 2012 at 11:46 pm
Commenting is closed