This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
David-Santiagos-Computer:servlet David$ lein pallet converge com.battletheory.deploy.nodes/main 1 -P virtualbox | |
INFO core - retrieving nodes | |
INFO core - converging nodes | |
INFO core - adjust-node-count :main 1 | |
INFO core - Starting 1 nodes for :main os-family :ubuntu | |
INFO vmfest - Template {:os-version-matches "10.10", :os-family :ubuntu} | |
INFO virtualbox - create-machine: Creating machine main-0 in /Users/David/.vmfest/nodes/main-0/main-0.vbox, overwriting previous contents | |
WARN virtualbox - Can't find a medium of type HardDisk located in/with id '/Users/David/.vmfest/models/vmfest-ubuntu-10-10-64bit-server.vdi'. | |
ERROR futures - Start of node exception: Assert failed: (instance? IMedium medium) | |
java.lang.AssertionError: Assert failed: (instance? IMedium medium) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
2011-07-14 22:42:39,114 ERROR [pallet.futures] (Thread-43) Adjust node count exception: null | |
java.lang.NullPointerException | |
at java.util.regex.Matcher.getTextLength(Matcher.java:1140) | |
at java.util.regex.Matcher.reset(Matcher.java:291) | |
at java.util.regex.Matcher.<init>(Matcher.java:211) | |
at java.util.regex.Pattern.matcher(Pattern.java:888) | |
at clojure.core$re_matcher.invoke(core.clj:3760) | |
at clojure.core$re_matches.invoke(core.clj:3794) | |
at pallet.compute.vmfest$regexp_match.invoke(vmfest.clj:255) | |
at pallet.compute.vmfest$fn__11399.invoke(vmfest.clj:259) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Failed to attach the hard disk (/Users/David/.vmfest/models/vmfest-ubuntu-10-10-64bit-server.vdi) to the slot SATA Port 0 of the machine virtualbox-sucks. | |
UUID {453994b7-6bd0-4060-875f-c8219f542355} of the medium '/Users/David/.vmfest/models/vmfest-ubuntu-10-10-64bit-server.vdi' does not match the value {9b60da5f-2d55-4361-a482-722ced16c2eb} stored in the media registry ('/Users/David/Library/VirtualBox/VirtualBox.xml'). | |
Failed to attach the hard disk (/Users/David/.vmfest/models/vmfest-ubuntu-10-10-64bit-server.vdi) to the slot SATA Port 0 of the machine virtualbox-sucks. | |
This machine does not have any snapshots. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(defpallet | |
:services | |
{:aws {:provider "aws-ec2" | |
:identity ";)" | |
:credential "tb4tch/43va"} | |
:virtualbox | |
{:provider "virtualbox" | |
:images | |
{} | |
:model-path "/Users/David/.vmfest/models" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
echo "Add java environment to /etc/environment..." | |
{ pallet_set_env() { | |
FLAGS "$@" || exit 1 | |
eval set -- "${FLAGS_ARGV}" | |
k=$1 | |
v=$2 | |
s=$3 | |
if [ ! $(grep "${s}" /etc/environment) ]; then | |
sed -i -e "/${k}/ d" -e "$ a \\ | |
${s}" /etc/environment |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
INFO core - retrieving nodes | |
INFO core - converging nodes | |
INFO core - adjust-node-count :stage 1 | |
INFO core - Starting 1 nodes for :stage os-family | |
INFO jclouds - OS is :ubuntu | |
INFO jclouds - building node template for :stage | |
INFO jclouds - authorizing /Users/David/.ssh/id_rsa.pub | |
INFO jclouds - options {:inbound-ports [22 80 443], :image-id "us-east-1/ami-a6f504cf", :hardware-id "m1.small"} | |
WARN compute - to avoid creating temporary keys in aws-ec2, use templateOption overrideLoginCredentialWith(id_rsa) | |
WARN compute - to avoid creating temporary keys in aws-ec2, use templateOption overrideLoginCredentialWith(id_rsa) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(defmacro with-ssh-tunnel | |
"Execute the body with an ssh-tunnel available for the ports given in the | |
tunnels map. tunnels should be a map from local ports (integers) to either | |
1) An integer remote port. Remote host is assumed to be 'localhost'. | |
2) A vector of remote host and remote port. eg, [\"yahoo.com\" 80]. | |
Automatically closes the connection (and port forwards) on completion." | |
[request tunnels & body] | |
`(clj-ssh/with-ssh-agent [(execute/default-agent)] | |
(let [user# (:user ~request) | |
node-address# (compute/node-address (:target-node ~request)) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
David-Santiagos-Computer:servlet David$ cake pallet lift com.battletheory.deploy.nodes/main :deploy @dev -- -P virtualbox | |
Exception in thread "main" java.lang.Exception: Unable to resolve symbol: execute in this context (file.clj:40) | |
at clojure.lang.Compiler.analyze(Compiler.java:5205) | |
at clojure.lang.Compiler.analyze(Compiler.java:5151) | |
at clojure.lang.Compiler$InvokeExpr.parse(Compiler.java:3036) | |
at clojure.lang.Compiler.analyzeSeq(Compiler.java:5371) | |
at clojure.lang.Compiler.analyze(Compiler.java:5190) | |
at clojure.lang.Compiler.analyze(Compiler.java:5151) | |
at clojure.lang.Compiler$BodyExpr$Parser.parse(Compiler.java:4670) | |
at clojure.lang.Compiler$LetExpr$Parser.parse(Compiler.java:4941) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
david@ubuntu:~$ sudo cat /var/log/tomcat6/catalina.2011-06-04.log | |
Jun 4, 2011 7:09:57 PM org.apache.coyote.http11.Http11Protocol init | |
INFO: Initializing Coyote HTTP/1.1 on http-8080 | |
Jun 4, 2011 7:09:57 PM org.apache.catalina.startup.Catalina load | |
INFO: Initialization processed in 2689 ms | |
Jun 4, 2011 7:09:57 PM org.apache.catalina.core.StandardService start | |
INFO: Starting service Catalina | |
Jun 4, 2011 7:09:57 PM org.apache.catalina.core.StandardEngine start | |
INFO: Starting Servlet Engine: Apache Tomcat/6.0.28 | |
Jun 4, 2011 7:09:57 PM org.apache.catalina.startup.HostConfig deployDirectory |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Doesn't work: | |
============= | |
...yadda yadda... | |
:dependencies [[org.clojure/clojure "1.2.0"] | |
[org.clojure/clojure-contrib "1.2.0"] | |
[org.jclouds.provider/aws-s3 "1.0-SNAPSHOT"]] | |
:dev-dependencies [[org.jclouds/jclouds-all "1.0-SNAPSHOT"] | |
[swank-clojure "1.3.1"] | |
[cake-pallet "0.5.0"] | |
[org.cloudhoist/pallet "0.5.1-SNAPSHOT"] |