public
Last active

juju rails stack

  • Download Gist
gistfile1.sh
Shell
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22
#!/bin/bash
 
juju_root=$HOME
juju_env=${1:-"-ecanonical"}
 
###
 
echo "deploying stack"
 
juju bootstrap $juju_env
 
juju deploy $juju_env --repository "$juju_root/charms" local:mysql
 
juju deploy $juju_env --repository "$juju_root/charms" --config ~/rails-sample.yaml -n3 local:rails myapp
juju add-relation $juju_env mysql myapp
juju expose $juju_env myapp
 
juju deploy $juju_env --repository "$juju_root/charms" local:haproxy head
juju add-relation $juju_env myapp head
juju expose $juju_env head
 
echo "done"

Please sign in to comment on this gist.

Something went wrong with that request. Please try again.