Hi Peter,
On Mar 3, 5:39 pm, Peter Booth pbo...@nocoincidences.com wrote:
Gerhardus,
On Mar 2, 2009, at 11:46 AM, Gerhardus Geldenhuis wrote:
Hi Peter,
I already use the multistage gem which works very well for us.
multistage is excellent at providing a structure for stage-specific
Hi
It would be nice to have something like the following:
namespace config
task :copyconfig, :roles = appservers
do_something
end
task :copyconfig, :roles = dbservers
do_something
end
end
the idea being that if you call config.copyconfig it will get called
twice but for each
Hi
I want to create custom config files and would appreciate any tips if
anyone has attempted the same thing.
I am planning to do it in the following way:
Download the config files using run command with svn
insert and append the config files using the run command with sed and
awk based on the
}
monit_config
end
On Mar 2, 2009, at 9:50 AM, Gerhardus Geldenhuis wrote:
Hi
I want to create custom config files and would appreciate any tips if
anyone has attempted the same thing.
I am planning to do it in the following way:
Download the config files using run
Hi
I am just glad someone is willing to step in so quickly.
I think capistrano and webistrano is both great products but with an
original focus on ruby/rails applications. I believe that with a bit
of effort ( a bit more in webistrano) it could easily be made to be
more generic. Currently I have
Hi
Version 1
task :check_lb_worker_exists, :roles = :apacluster, :on_error
= :abort do
if exists?(:modjk_loadbalancerworker) then
begin
run if wget #{wgetparams} 'http://$CAPISTRANO:HOST$/jkserver-
status?cmd=editfrom=listw=#{modjk_loadbalancerworker}' | grep
'ERROR'; then
a begin/rescue
clause, instead of an unless condition.
begin
some.task
rescue Exception = e
puts got exception: #{e}
end
Does that make sense? Exceptions bypass your program logic and require
explicit handling.
- Jamis
On 2/20/09 9:28 AM, Gerhardus Geldenhuis wrote
Hi
Is it recommended to use logger.info or should I rather be using puts?
Also is there options other than logger.info and I would appreciate it
if you could point me to the source code for logger which would
probably answer my second question.
Best Regards
/09 11:00 AM, Gerhardus Geldenhuis wrote:
Hi
Is it recommended to use logger.info or should I rather be using puts?
Also is there options other than logger.info and I would appreciate it
if you could point me to the source code for logger which would
probably answer my second question
Found a good solution:
unless exists?(:app_path)
abort I failed
end
On Feb 17, 10:58 am, Gerhardus Geldenhuis
gerhardus.geldenh...@gmail.com wrote:
Hi
I assumed that if I purposely raised an exception it would show my
error message and stop. Capistrano/ruby does
Hi
I assumed that if I purposely raised an exception it would show my
error message and stop. Capistrano/ruby does that but it also included
a whole bunch of other items that would confuse my users.
deploy-config.rb:92:in `load': I failed (RuntimeError)
from
Hi
I have managed to confuse myself again...
I am trying to do the following:
my staggered deploy scripts cycles through a list of application
servers doing the following:
disable app server on multiple load balancers
install new app
enable app server on multiple load balancers
continue on to
On 2/16/09 5:09 AM, Gerhardus Geldenhuis wrote:
I have also put the relevant code onhttp://pastie.org/390600
Regards
--~--~-~--~~~---~--~~
To unsubscribe from this group, send email to
capistrano-unsubscr...@googlegroups.com
For more options, visit this group
/dev/null
maybe a wrapper to allow easier/simplified http interaction with put
and get might be usefull. (perhaps even some xml manipulation)
Anyway just some random thoughts.
Regards
On Feb 16, 3:44 pm, Jamis Buck ja...@37signals.com wrote:
On 2/16/09 8:37 AM, Gerhardus Geldenhuis wrote
Hi
I vaguely recall seeing a way to test for empty or non-existent
variables but could not find it going through my archives.
I want to know if there is a way to test whether a variable has been
declared/have a value?
Basically I want to write a pre-flight check program that checks that
users
:
See the #exists?(:var) method:
http://wiki.capify.org/article/Exists%3F
Hope that helps,
Jamis
On 2/13/09 7:29 AM, Gerhardus Geldenhuis wrote:
Hi
I vaguely recall seeing a way to test for empty or non-existent
variables but could not find it going through my archives.
I want
Hi
is any caching that capistrano does only for the duration of a
running cap command?
I have seen some weird errors which I thought might potentially
caching related.
Basically I thing this variable was not being set $CAPISTRANO:HOST$
properly which caused some of the tasks to not work
:31 pm, Jamis Buck ja...@37signals.com wrote:
find_servers(:roles = :foo).each do |server|
run disable server on load balancer, :host = server
run install new software, :host = server
run test server, :host = server
# etc.
end
- Jamis
On 1/28/09 8:16 AM, Gerhardus Geldenhuis wrote
On 1/30/09 7:51 AM, Gerhardus Geldenhuis wrote:
True,
But I do need multistage to deploy to different stages eg production,
test, demo, load-test etc.
I have also defined stages for different application stacks in
production for example. eg prod-app1, prod-app2
We need to deploy our
recommendation is to put the command in
a script and execute the script on the server, e.g.:
put some big long command to execute, /tmp/script.sh
run sh -c /tmp/script.sh
- Jamis
On 1/28/09 10:29 AM, Gerhardus Geldenhuis wrote:
Thanks Lee,
That will certainly be usefull and solve some
On 1/29/09 5:33 AM, Gerhardus Geldenhuis wrote:
Thanks, that was my second option to create a script on the local box,
however I like the clean approach of keeping all the logic on the
deployment box which means I don't have to worry about any deployment
requirements.
Would the abbility
are just pure ruby.
- Lee
2009/1/27 Gerhardus Geldenhuis gerhardus.geldenh...@gmail.com
Hi
I am looking at Ruby editors available and was wondering if anyone has
a favourite editor they want to recommend for capistrano or that can
be adapted to work well with capistrano. A colleague
of code where it
was declared even if it weren't part of my application which was
powerfull and an excellent way to learn.
Regards
On Jan 28, 10:04 am, Gerhardus Geldenhuis
gerhardus.geldenh...@gmail.com wrote:
Hi
Thanks for the replies, I am not yet ready to give up on vi/vim but
thought
Hi
I have created the following alias for a deployer user:
alias capg='cap -f /home/deployer/tomcat-deploy/multistage/
testingmultstage.rb'
however when the user runs capg he/she gets the following error:
/usr/lib/ruby/gems/1.8/gems/capistrano-2.5.3/lib/capistrano/
://www.ruby-doc.org/core/classes/File.html#M002565
.
- Hope this helps.
2009/1/28 Gerhardus Geldenhuis gerhardus.geldenh...@gmail.com
Hi
I have created the following alias for a deployer user:
alias capg='cap -f /home/deployer/tomcat-deploy/multistage/
testingmultstage.rb
Hi
I need to do something like the following:
for server in role do
Disable server on load balancer
Install new software
Test Server
Enable server in load balancer
If successful then deploy next server else fail/rollback.
done
The individual steps is not a problem but I am unsure how
test server, :host = server
# etc.
end
- Jamis
On 1/28/09 8:16 AM, Gerhardus Geldenhuis wrote:
Hi
I need to do something like the following:
for server in role do
Disable server on load balancer
Install new software
Test Server
Enable server in load balancer
Hi
I am looking at Ruby editors available and was wondering if anyone has
a favourite editor they want to recommend for capistrano or that can
be adapted to work well with capistrano. A colleague is using Komodo
which is commercial but looks quite nice. atm I am using vim which has
so far been
Hi
I have been doing some reading about how to implement multistaging but
I am not sure which route I should be following. I would really
appreciate some advice/thoughts.
I have found Multistage:
http://weblog.jamisbuck.org/2007/7/23/capistrano-multistage
and another possible method
Hi
Is there a way to display a string rather than the command executed
with run in a task. Some of my run commands are quite involved and
does not look very intuitive or clear on the screen. I would rather
show the operator a simple output with a log file somewhere else that
stores all the
Hi am reading through the archives at the moment and am missing some
good examples of how to actually use multistage.
I realized that I have no idea what to do further other defining my
stages.
Regards
On Jan 23, 3:12 pm, Gerhardus Geldenhuis
gerhardus.geldenh...@gmail.com wrote:
Hi
I have
:
Hi Gerhardus,
Where are you upto so far?
- Lee
2009/1/23 Gerhardus Geldenhuis gerhardus.geldenh...@gmail.com
Hi am reading through the archives at the moment and am missing some
good examples of how to actually use multistage.
I realized that I have no idea what to do further
except exit
with a status code of 1.)
- Jamis
On 1/21/09 10:42 AM, Rafael G. wrote:
Gerhardus Geldenhuis wrote:
Hi
Is there a way to run different tasks based on the exit status of a
run command? Also how can I force a task to fail or succeed, how is
the failure/success of a task
Hi
vs might be a bit of a controversial term. I am really interested in
peoples opinions about the overlapping or symbiotic relationship
between capistrano and puppet. If you are using both tools, could you
expand on the relationship between the tools in your usage of them?
I have some thoughts
Hi
I have written the following script to monitor succesfull startup of
our webapp:
I am trying every second to get a webpage but also have a timeout
which will fail the task after 60 seconds.
task :monitor_app_startup, :roles = :testct do
run -CMD
for ((n=0; n61; n++ )); do
if wget
maculike2:~ mbailey$ if wget --tries=1 --wait=1 --connect-timeout=1
--timeout=1 --quiethttp://www.google.com/;then echo 'success'; else echo
'fail'; fi;
success
On Fri, Jan 23, 2009 at 2:13 AM, Gerhardus Geldenhuis
gerhardus.geldenh...@gmail.com wrote:
Hi
I have written the following
Thanks,
I need to configure wget that it does not try 60 times in one second
but that is just some man page reading.
My confusions were that I was assuming that capistrano would handle
exit 1 statements and not fail completely.
Regards
On Jan 22, 3:56 pm, Mike Bailey m...@bailey.net.au wrote:
On Jan 22, 4:08 pm, Jamis Buck ja...@37signals.com wrote:
The run() command does not return success/failure. If it succeeds, it
returns. If it fails, it raises an exception.
To get the result of a command, you can use the capture() method:
http://wiki.capify.org/article/Capture
Note,
capistrano.
Regards
On Jan 22, 4:14 pm, Jamis Buck ja...@37signals.com wrote:
On 1/22/09 4:12 AM, Gerhardus Geldenhuis wrote:
I have found this very usefull, however I do not understand the
difference between HOSTS and HOSTFILTER. It would be great if you
could explain it from another angle
Hi
This is not really capistrano related anymore but I thought it
worthwhile to mention for anyone following the thread.
I have tried a number of wget flags:
wget longtct03g:8080/gta/buildInfo.jsp -O - --connect-timeout=1 --
timeout=1 --tries=60 --wait=1 --waitretry=10 --retry-connrefused
Hi
Is there a variable that I can access to get the name of each server
in the role?
I want to do something like the following:
task :idfile, :roles = :testtct do
run touch /tmp/#{testtct.name}
end
Regards
--~--~-~--~~~---~--~~
To unsubscribe from this
Hi
Is there a way to run different tasks based on the exit status of a
run command? Also how can I force a task to fail or succeed, how is
the failure/success of a task determined/defined.
Regards
--~--~-~--~~~---~--~~
To unsubscribe from this group, send email to
Hi
I can't get the following code snippet to work.
task :promptme, :roles = :gg do
set(:user) { Capistrano::CLI.ui.ask(User name: ) }
end
I expected it to prompt me on the command line when running cap
promptme but it does not prompt me at all.
cap promptme
* executing `promptme'
When
Hi
I saw the following code on
http://blog.innerewut.de/2007/9/28/capturing-output-in-capistrano
and thought it was capistrano
run cat /etc/passwd do |ch, stream, data|
if stream == :err
logger.debug capured output on STDERR: #{data}
else # stream == :out
logger.debug capured
Hi
I am writing a task that undeploys our application in tomcat.
Normally if we do it by hand we remove the war file and then watch the
tomcat webapp directory for the automatic deletion of the application
directory.
I would appreciate advice on the best way to achieve something similar
like
Hi
I have emailed this from my gmail account earlier but did not see the
message appear on the group. Apologies if it is double posted.
I have been going through same of the example scripts on the mailing
list page and came acrross this.
Its just an extract from:
in this context.
This is not part of Capistrano but is a Monit configuration file.
Monit is a process level monitoring tool that can react to resource
consumption.
Jonathan
--
Jonathan Weiss
http://blog.innerewut.de
http://twitter.com/jweiss
--
Gerhardus Geldenhuis
Registered Linux User
47 matches
Mail list logo