- From: Jesse Campbell <
>
- To:
- Subject: [chef] Re: Re: Re: Re: example using application_java?
- Date: Wed, 30 May 2012 15:04:27 -0400
I'll give that a try in the next week or two and see how far I get. We
have a deadline for go-live, and migration doesn't have to be ready
for the first deploy, so I'll have to wait until things are up before
I can revisit it.
Thanks!!!
On Wed, May 30, 2012 at 3:03 AM, Andrea Campi
<
>
wrote:
>
On Wed, May 30, 2012 at 12:37 AM, Jesse Campbell
>
<
>
>
wrote:
>
> We deploy our rails apps in war/java containers using something called
>
> Warbler (this comes from the developers, I haven't investigated it
>
> myself). The dev group wants us to implement capistrano, but i feel
>
> like that is like saying we should use puppet for this one thing...
>
> we're a chef shop, do it the chef way is how I want to respond... but
>
> so far I haven't found what i need.
>
> We may continue using Bryan's tomcat6, and use his maven LWRP for
>
> deploying the wars... but i think even that may leave us without a
>
> migrations plan...
>
> perhaps there is a way to use some aspects of the deploy resource to
>
> orchestrate migrations... i'll investigate later in the week (for now
>
> I just need to get things running once to get the PMs off my back).
>
>
For a quick and dirty fix, you could try subscribing to the
>
java_remote_file resource.
>
I haven't actually tried this so YMMV, but it should be doable.
>
>
I'd start with something like this:
>
>
>
>
assuming you have a:
>
>
application "app-test" do
>
...
>
end
>
>
then in your recipe add something like:
>
>
execute "migrate app-test" do
>
command "rake db:migrate" # or whatever shell command you need to run
>
action :nothing
>
subscribes :run, resources(:java_remote_file => "app-test")
>
end
>
>
Maybe it will work on the first attempt :)
>
If it won't, run it with chef-client -l debug and email me the log
>
(private email) and I'll walk you through the rest.
>
Once we get you set up, I'll document it for the next poor soul.
>
>
Andrea
Archive powered by MHonArc 2.6.16.