Mike, Thanks for representing over at SO! Too many haters in open source, I
only hope I'm doing justice to a very, very mature, and widely used piece of
software!
--
* You received this message because you are subscribed to the Google Groups
Capistrano group.
* To post to this group, send email
The README also links to this intermediate page. Does it serve a purpose?
There's a v3 in the works, so I split the docs into v2 and v3, someone
apparently thought better of my decision, and moved the v2 to the homepage
(makes sense, I suppose, for now) - I'll see if I can find a few minutes
Manuel,
Capistrao is for deploying application code, whilst some often mis-use it
for server provisioning, this is a problem best solved with chef/puppet
and/or by competent sysadmins
- Lee
On 23 May 2011 20:44, Manuel Vázquez Acosta manue...@uci.cu wrote:
Has anyone tried to deploy Ruby
Can anyone suggest how I can stop Capistrano from trying to cache my
password?
Use SSH keys. There's basically no good reason not to do so in 2011, and
deploying on servers which still use passwords is just not smart (with the
immense power of password cracking tools)
Future versions of
And, if your problem *only* relates to sudo passwords, you should endeavor
not to require sudo (restart, use monit and checksum the REVISION file,
trigger a restart). Failing that, ensure that there's a group of users with
access to the restart commands passwordless via sudo groups.
- Lee
--
*
Peter, sorry - not much I can do here to alleviate your pain, if you have
some time I'd be more than happy to work with you on improving the code
though.
--
* You received this message because you are subscribed to the Google Groups
Capistrano group.
* To post to this group, send email to
Wes, naturally - Cap's DSL was originally styled after rake, it's an easy
mistake to make. Depending how you want to do it, you can simply `require`
your `Rakefile` in the Cap script, (ensuring of course to include Rake, if
that directive is absent from your rakefile), and then you call tasks with
Dan:
after( 'deploy:update' ) do
# My code here
end
- Lee
--
* You received this message because you are subscribed to the Google Groups
Capistrano group.
* To post to this group, send email to capistrano@googlegroups.com
* To unsubscribe from this group, send email to
deploy.rb, or if you're using multistage, then in the appropriate stage
file. Also, please see the documentation here - a cursory search for After
in the API docs revealed this;
http://rubydoc.info/github/capistrano/capistrano/master/Capistrano/Configuration/Callbacks:after-
perhaps search wasn't
didn't search through,
though I should have, the API itself.
-Dan
On Jun 3, 12:26 pm, Lee Hambley lee.hamb...@gmail.com wrote:
deploy.rb, or if you're using multistage, then in the appropriate stage
file. Also, please see the documentation here - a cursory search for
After
in the API
This is patched here https://github.com/capistrano/capistrano/pull/61 - but
it's not merged yet, I'm stacked with work, but I'll be merging these things
at the weekend and rolling a new release.
- Lee
--
* You received this message because you are subscribed to the Google Groups
Capistrano
Yes, Carol's patch is pending to be pulled, more than likely this weekend
when I have some free time to think about it!
- Lee
--
* You received this message because you are subscribed to the Google Groups
Capistrano group.
* To post to this group, send email to capistrano@googlegroups.com
* To
deploy_via :copy is designed to upload from your workstation, in the even
that your application servers cannot reach your git repository.
- Lee
--
* You received this message because you are subscribed to the Google Groups
Capistrano group.
* To post to this group, send email to
James,
There are some techniques, often in rails land this is solved with ERB
files, which are processed in the context of a certain environment, here's a
gist with a Rake task (don't be too afraid of Rake, it's fairly sane, and
there's probably something similar for PHP, and an ERB apache2
Chef/Puppet to provision the servers, preferably Capistrano to deploy.
Depending how elastic your setup needs to be, if you can't rely on humans
sitting at computers to do a deploy when you scale-up, the deploy may need
to be part of your Chef/Puppet setup… something like my app is a piece of
Eric,
I am trying to figure out how to get a task to only fire one time.
Tasks run once, they shouldn't run once per server they do run once on
each server
If you then have a task that should run on only one server in your group,
you need to isolate it somehow, name it with a responsibility,
Please paste a more complete log, also your workstation needs to have Git
installed.
- Lee
--
* You received this message because you are subscribed to the Google Groups
Capistrano group.
* To post to this group, send email to capistrano@googlegroups.com
* To unsubscribe from this group, send
Adam,
Bundler is unable to write to your Rubygems (GEM_HOME) directory, and is
asking for your `sudo` password, you should check the bundler docs, and/or
rvm if appropriate, and find out how to install to a shared location.
If you are on Ubuntu, (as far as I know, but please check) you are out
Matt, as far as I know there's nothing like cap deploy result - you can
assume if you are in an after-callback that it was successful, otherwise the
transaction would have been aborted earlier in the process.
As for local username - there's some options here, shell-out, to whoami,
if all your
What problem are you trying to solve by not checking out the branch? Cap
does this to ensure some measure of cleanliness, and make sure that your
deploys are always atomic.
--
* You received this message because you are subscribed to the Google Groups
Capistrano group.
* To post to this group,
Whatever google sitemap generator is, is not affiliated with Capistrano, and
you should probably ask their support.
Beware that most plugins which generate things (assets, site maps, caches,
etc) should normally be configured to persist their content between deploys,
and be symlinked in an :after
Too fast on the keyboard there, the 2nd example would be in case of success.
--
* You received this message because you are subscribed to the Google Groups
Capistrano group.
* To post to this group, send email to capistrano@googlegroups.com
* To unsubscribe from this group, send email to
://www.ericsink.com/vcbe/html/web_development.html
Basically, a web application need only ever deploy from the same
release branch, i.e. we don't need to create a new branch for every
deployment.
On Aug 2, 5:01 pm, Lee Hambley lee.hamb...@gmail.com wrote:
What problem are you trying to solve
I take it back, absolutely no tests… damn why do people write software that
way these days. Use at your own risk.
--
* You received this message because you are subscribed to the Google Groups
Capistrano group.
* To post to this group, send email to capistrano@googlegroups.com
* To unsubscribe
God helps those who help themselves.
https://github.com/capistrano/capistrano/wiki
Please feel welcome to come back with focused questions.
--
* You received this message because you are subscribed to the Google Groups
Capistrano group.
* To post to this group, send email to
Please ask a focused question.
On 8 August 2011 17:43, sawan talreja sawantalr...@gmail.com wrote:
Yeah your right...but I didn't find my answers...
I am newbie in Capistrano and Rails..
please help me out...
thanks
--
* You received this message because you are subscribed to the
This was a user submission to Capistrano, I haven't yet used Rails 3.1, I
can only suggest you file a report as a bug at Github, and /cc @cgriego
(just mention him) in the ticket, maybe he can help you there. I don't know
if he's registered on the mailing list.
--
* You received this message
Ok, please take discussion of another project to your own mailing list. This
isn't alternatives-to-capistrano-announce, that's the 2nd time in a week
someone has been posting here about their own project. A brief post is
acceptable, but hijacking the support list for discussions about
alternatives
Damn, 20 minutes after I post that this isn't an announcements mailing list
for your own projects…
On 13 August 2011 19:53, Matthew Macdonald-Wallace mattmacw...@gmail.comwrote:
Hi all,
I've just put CapistranoCobbler (CapCob) live on github @
https://github.com/proffalken/capistrano-cobbler
Matt, no problem - in this case the enhancement is valid, but I would much
rather have heard about it via the changelog or twitter, the other thread
really got my goat yesterday; as it was a long and drawn out discussion
about something completely off topic.
--
* You received this message
Stuart,
The only option is `:no_release = true` on the role/server declaration, but
beware this does more than disable the clone/checkout - it also disables
anything related to source code (think… database server)
If there's a real problem checking our your source from Git, you should
perhaps
It's high time Capistrano got some love, so ask your friends, harass the
DevOps guys, and please come and file your bug reports and feature requests.
Here's my personal short list:
* Improvements to the Capistrano shell
* Improvements to the DSL (I'd love to switch to Thor, but I think it's too
One of the things I would like is to be able to give git (and git
submodule) a --references option.
That fits with this, which is pending to be pulled;
https://github.com/capistrano/capistrano/pull/80 - Where can I read about
“--references”, there's nothing obvious in the man pages?
I will
Stuart,
I'd refute the part about using a platform-specific package management tool
to deploy your application! If we're being strict about it - why not package
your source code as a Gem, and host your own ruby gems repository on the
server? (I'm assuming this is a Ruby app)
You'd benefit from
dbray, I'll hear that - please take it to a ticket… that sounds useful.
--
* You received this message because you are subscribed to the Google Groups
Capistrano group.
* To post to this group, send email to capistrano@googlegroups.com
* To unsubscribe from this group, send email to
Robert,
Please share your config files.
- Lee
--
* You received this message because you are subscribed to the Google Groups
Capistrano group.
* To post to this group, send email to capistrano@googlegroups.com
* To unsubscribe from this group, send email to
You're not setting :scm_password?
- Lee
--
* You received this message because you are subscribed to the Google Groups
Capistrano group.
* To post to this group, send email to capistrano@googlegroups.com
* To unsubscribe from this group, send email to
capistrano+unsubscr...@googlegroups.com
Prompting the user when needed is iffy at best even under *NIX, on Windows
i'm surprised your machine hasn't caught fire :) As a general rule with
deployment aim for no human interaction. If you feel generous, you could add
a note to the docs to the effect that in your experience prompting for an
Nicholas,
Bear in mind that changing something like this for us as maintainers, will
break a lot of people's deploys; until the advent and proliferation of
bundler, we've been effectively prevented from making changes to the
`deploy.rb` file from the Gem, because people see this behavior as part
Justin,
There's nothing special to do, but consider using something proper such as
popen4, or you can try run_locally, which is a helper from Cap.
- Lee
--
* You received this message because you are subscribed to the Google Groups
Capistrano group.
* To post to this group, send email to
No, there isn't Serg, we'd be open to adding some in-scm callbacks, if there
are some common paradigms which apply to the popular SCMs.
--
* You received this message because you are subscribed to the Google Groups
Capistrano group.
* To post to this group, send email to
Robby,
There's no way to do this from the outside, you'd have to modify the
:update_code task to run with the :once = true argument. This isn't such a
big deal, simply take the deploy.rb out of the gem, and drop it in your
project (and update the require/load in your Capfile accordingly), this is
Donovan,
Thanks!
- Lee
--
* You received this message because you are subscribed to the Google Groups
Capistrano group.
* To post to this group, send email to capistrano@googlegroups.com
* To unsubscribe from this group, send email to
capistrano+unsubscr...@googlegroups.com For more options,
M,
I personally have implemented deployments based on Capistrano for unnamable
clients who had the largest government in the western hemisphere as their
client; the site in question had millions of hits per week; and was hosted
on 140 VPS servers on EC2.
In Europe I have consulted with a
Matt,
Please, drop me a mail (see headers) - I'd like to know what could be
improved about cap to make working with Puppet easier, Rafa, I know you're
also using puppet, maybe we could compare notes and see which improvements
can be made?
- Lee
--
* You received this message because you are
Matt, the most simple way would be to take a look at my railsless deploy
gem, this is as close as Cap gets to plugins - the trick is the block that
contains everything, ensures that the code doesn't run until the Cap
executable loaded the cap engine/etc …
Let me know if that helps/doesn't?
- Lee
Hi Amain,
You should set deploy_to in the stage file, and set it before it's used
anywhere. (Ideally before you `load` deploy.rb) - here's the definition at
Github:
https://github.com/capistrano/capistrano/blob/master/lib/capistrano/recipes/deploy.rb#L28
It's _cset which is conditional-set (you
Hi Brian,
You're right - that's a hell of a long time!
I think the problem is that there's no traffic on the wire, I've seen people
work around this by doing with he block-form of run() and writing \0 to the
channel from time to time to keep it alive; YMMV, if you come up with
something
Sorry patrik, there are some ways (wrapping the script) - but it's not a
high priority. If you wanna request it via the Github issue tracker, someone
may be inspired to work on it with you.
- Lee
--
* You received this message because you are subscribed to the Google Groups
Capistrano group.
*
Patrik,
In your deploy, I'd recommend a run() which is always truthy (that is, if
it's optional), the easiest way would be:
task :remove_disabling_file, :roles = [:app] do
file_name = 'deply-failed.html'
run(if [ -e #{file_name} ] then; unlink #{file_name}; end )
end
(completely un-tested,
Finally, regarding on_rollback, take a look in
https://github.com/capistrano/capistrano/blob/master/lib/capistrano/recipes/deploy.rbat
how this can be used, there's a few examples in there, simply have a
skim
through the file.
I might also draw your attention to the tasks:
You should use the :copy option, which deploys using a tarball. (and/or use
a source hosting service, local SVN is as bad as no source control at all,
what if your notebook takes a swim under a spilled drink… goodbye code!)
- Lee
--
* You received this message because you are subscribed to the
Jack,
Windows doesn't support form() I can't actually tell you why something
appears to need fork, but honestly don't use Windows for deployment, and
don't use local SVN. In 2011 you'd be hard pressed to find a good reason not
to use Gitorious, or Github, or insert any number of providers here,
“Capistrano is a developer tool for deploying web applications. It is
typically installed on a workstation, and used to deploy code from your
source code management (SCM) to one, or more servers.”
( via https://github.com/capistrano/capistrano/wiki/Documentation-v2.x )
There are of course ways,
I would assume, you should build the warfile using whatever it is one builds
warfiles with, then put it either directly to the server using the upload()
function in Cap (or Net::{SSH, SCP}).
An alternative would be to look at the Copy deploy strategy and write your
own which builds a war, and
Javi,
Please contact their support, this isn't the place for help with 3rd party
tools. One point is that the password you being asked for is probable for
myfirm@thegitrepository, unless the server has a key configured at
thegitrepository. Github has good documentation on deploy keys which you
Yes. Note, on the first deploy you'll need to do that by hand ^^ otherwise
the first time you use this code, you'll blow away all the uploaded images.
--
* You received this message because you are subscribed to the Google Groups
Capistrano group.
* To post to this group, send email to
Why is this…
Because Capistrano expects (reasonably, I believe) that all your servers
have the same code deployed, failed deploys clean themselves up, and if
you're adding machines to the cluster, you aught to be doing it in a way
that makes them consistent with the existing node in the
Pascal,
Please feel free to add this under the using cap with other frameworks
heading at http://www.capistranorb.com/ - it's expanding slowly :)
- Lee
--
* You received this message because you are subscribed to the Google Groups
Capistrano group.
* To post to this group, send email to
Pascal, that's perfect - I just looked at the wiki, I'd remembered the
heading name wrong… thanks for your contribution! Viva la Capistrano
--
* You received this message because you are subscribed to the Google Groups
Capistrano group.
* To post to this group, send email to
You might want to look here, it's really not pretty – but it worked as a
proof of concept, there has to be a nicer way though:
https://github.com/leehambley/capistrano-yaml-multistage/blob/master/Capfile#L29
Long story short, that's a Rails 2.x app where I wanted to be able to do
multistage
thing he was trying to do.
He was creating the right tasks nut he was trying to create a 'meta' task
that serially called the methods of each configured stage. So he can call
them individually and optionally together.
If I read his code correctly
On Oct 3, 2011, at 1:45 PM, Lee Hambley
you should run bundle exec cap…
On 4 October 2011 05:12, Clemence Lelong cleme...@heyrex.com wrote:
Hi,
I saw that somebody had the same error and resolved it but I don't
understand. Could you help me?
My server is debian lenny. My gem list is :
capistrano (2.9.0)
highline (1.6.2)
Great advice Donovan, thanks for sharing!
- Lee
--
* You received this message because you are subscribed to the Google Groups
Capistrano group.
* To post to this group, send email to capistrano@googlegroups.com
* To unsubscribe from this group, send email to
You can set db to your app server IP… this is the server responsible for
running the migration. Had you been on the list a couple of weeks ago, we've
been discussing changes to that.
--
* You received this message because you are subscribed to the Google Groups
Capistrano group.
* To post to
Ramón, can you please Gist/pastie your /entire/ Capfile, deploy.rb and the
relevant stage files, I need to check what MRI 1.9 encoding headers you have
in the files.
- Lee
2011/10/20 Ramón Cahenzli ramon.cahen...@gmail.com
Hi everyone,
With Ruby 1.8, all our deployment recipes worked fine.
There is of course the parallel helper [1], slightly different of course,
but you aught to focus on more reliable restarts at your end, in 2011
mongrel is a poor choice, and there are many alternatives with better
restart semantics.
That's not to preclude it's inclusion, but it'd require some
Roger,
This query comes up time and time again, should they inherit, or not - I
think sadly there's no good answer, except to make it configurable (which
leads to a much less clean API), I'd really welcome some input, and would be
happy to help you write a decent patch, so that we can settle it
Donovan, the problem is as such I believe:
task :a, :roles = [:alpha, :beta] do
b
end
task :b, :roles = [:charlie] do
# When A calls me, should I run against
# [:alpha, :beta] or [:charlie]
end
Roger, did I understand you correctly?
--
* You received this message because you are
Webistrano is unfortunately obsolete, and no longer maintained (it was never
related to us guys) - the guys who wrote it do crop up on the Cap list from
time to time, but they focus their energy somewhere else now.
I'd recommend taking the webistrano gem apart to see how it makes that list,
or
Sorry Ian, CapMailer isn't anything official, you'll have to reach out to
the maintainer directly. Good Luck!
--
* You received this message because you are subscribed to the Google Groups
Capistrano group.
* To post to this group, send email to capistrano@googlegroups.com
* To unsubscribe from
No, but you should be able to leverage the features of the underlying
shell, and background the process with .
On 5 November 2011 13:22, Brian Carpio bcar...@thetek.net wrote:
Lets say I have the following
desc my task
task :my_task, :roles = :cluster do
run some command here
run some
I am trying to do a deployment to a ec2 micro instance.
Could be a bundler problem, take a look at the bundler notes/docs/list for
the discussions about using it in low-memory situations, otherwise …
It gets to the point where it triggers the assets precompile task and
after that the
cpu
Jim, good point, I didn't even think about that!
--
* You received this message because you are subscribed to the Google Groups
Capistrano group.
* To post to this group, send email to capistrano@googlegroups.com
* To unsubscribe from this group, send email to
No the multi-stage task is slightly special, and it doesn't work as you
might expect!
There's not a lot standing between a special all name which would call
both setup tasks, but unfortunately it doesn't exist right now, because…
The two stage names production and staging are meta tasks, which
I'm interested in the use case here, surely the whole point of stages is
that you don't deploy to both environments?
Likewise, multistage was always designed to have a testing, and a
production, actually it's incredibly simple (the meta tags just load an
alternative config file) - but it's
When you have two separate projects, they aught to be submodules of
oneanother (depending how the heirarchy makes sense) then your I18n deploy
is ssh me@theserver 'cd ./the/project/dir git submodule update i18n'
- Lee
--
* You received this message because you are subscribed to the Google
So leverage the power of your shell, you can run() something and pass the
appropriate nohup/background command to ask your shell to run it in the
background, which will leave cap free to move on to the next run() command,
etc.
- Lee
--
* You received this message because you are subscribed to
Then you have two independent projects, not two stages.
I recommend using git submodules, still - and tracking your i18n
separately, and when you need to deploy your translations, make a
one-liner task go to the app, and do a `git submodule update`. Then Git (a
content tracker) will track when
Subversion has Externals (which are the same as Git submodules)
And you don't have to hope that it happens before Symlink, you can hook
into after (deploy:)update_code - which runs inside of the rollback
transaction, and will allow you to scrap the deploy if you can't
checkout/link/whatever your
My alternative idea is create subfile on local host and copy it.
but If I can use here documents, It is best way for me.
That's unfortunately the best answer, as the sh/ruby heredoc formats are so
similar.
- Lee
--
* You received this message because you are subscribed to the Google Groups
There's no plugin, this is an effect of the way connection handling is
done. Perhaps you'd be interesting in examining Net::SSH-Multi which might
be the next big change to the Capistrano back-end.
- Lee
--
* You received this message because you are subscribed to the Google Groups
Capistrano
You can use Capistrano::CLI::ask in a early task to ask for such
credentials, here's something from my app which I use to ask the user for
the branch name, with a sensible default, this is shared between :
set :branch, lambda do
a = Capistrano::CLI.password_prompt(SHA1/Branch/Tag to deploy
I meant, by written long form that it wasn't valid syntax… but it was
supposed to be easier to understand:
set(:branch, lambda { })
is the required way...
On 15 November 2011 18:30, Craig White craig.wh...@ttiltd.com wrote:
On Nov 15, 2011, at 10:07 AM, Lee Hambley wrote:
You can use
Did you come up with some way to fork multiple parallel deploys, of
multiple projects?
It sounds very much like you are doing something very wrong.
--
* You received this message because you are subscribed to the Google Groups
Capistrano group.
* To post to this group, send email to
But eventually were you able to get it down to a one-liner shell command,
or is it still two deployments?
You mentioned `forking` - if you were really using fork, you would inherit
any pre-set variables, but when they're not pre-set, then you would have to
enter them into each individual child
Based on what I saw he is not forking; he is creating a sub shell via a
system() call; so there will be no sharing of anything from the run time
parent cap.
Acknowledged, bit of a shame, would be possible to set up the variables,
fork and load the individual depoys, I expect… but honestly
That depends entirely on correctly configuring DNS, a web server, your
database server, an application server, and more - please consult your
distributions documentation on how to do those things.
- Lee
--
* You received this message because you are subscribed to the Google Groups
Capistrano
This method hasn't changed, permission denied means that something
changed on your server, not always permission, this can also happen if you
have run out of disk space, or if the file was in use, etc.
For this purpose, SFTP and SCP aught to behave the same.
- Lee
--
* You received this
It might be that something in your system configuration is preventing
Apache reading symlinks.
--
* You received this message because you are subscribed to the Google Groups
Capistrano group.
* To post to this group, send email to capistrano@googlegroups.com
* To unsubscribe from this group,
Daniel,
Are you certain that it's asking for the SSH password for logging on to the
servers, or for checking out the code from the repository? (and it's not
mentioned, but I assume all SSH passwords are the same, which is a horrible
idea) You ought to be using SSH keys [1].
- Lee
---
[1]
Daniel,
I can't say, only that nobody is seriously using Capistrano with passwords,
it's a horrible practice, and might even be rendered impossible one day (at
it encourages bad setups, such as the one you were aiming for).
Please report back (but if I were you, I wouldn't waste any time
Happy you have it working, have fun with Cap, and feel welcome to come back
when you need more help.
- Lee
--
* You received this message because you are subscribed to the Google Groups
Capistrano group.
* To post to this group, send email to capistrano@googlegroups.com
* To unsubscribe from
Via Capistrano you won't have any environment set, you've not posted the
rest of your config (specifically if you are asking for a tty) - but I'd
expect nagios is expecting some env vars which simply don't exist (and,
aren't supposed to exist) when working via Cap.
- Lee
--
* You received this
cap deploy:migrate # run migrations on an already deployed app with
outstanding migrations
cap deploy:migrations # run a new deployment, and run migrations inline
The behaviour is because many large sites need to take care of their
migrations especially.
cap deploy:cold perhaps should handle
Share your output logs, via gist or pastie, please.
--
* You received this message because you are subscribed to the Google Groups
Capistrano group.
* To post to this group, send email to capistrano@googlegroups.com
* To unsubscribe from this group, send email to
Jay, What exactly do you expect rake db:migrate does? It simply runs your
migrations, it does not copy local state, and images to the remote server,
that wouldn't make any sense.
--
* You received this message because you are subscribed to the Google Groups
Capistrano group.
* To post to this
You don't.
There's almost never, ever, ever a time you would want to overwrite
production data with your local testing data. (and therefore, no tool that
I know about to do it with)
--
* You received this message because you are subscribed to the Google Groups
Capistrano group.
* To post to
Please see the API documentation for Capture():
http://rubydoc.info/github/capistrano/capistrano/master/Capistrano/Configuration/Actions/Inspect:capture
And, perhaps more usefullly:
http://rubydoc.info/github/capistrano/capistrano/master/Capistrano/Configuration/Actions/Invocation:run
Where
Simply use a `before` hook and hook into anything before `update_code`.
On Monday, December 19, 2011 at 4:39 PM, Roch Delsalle wrote:
Hi,
I would like to know how I can execute a command on the server before
capistrano switches to the new sources. I want to backup some files
before the
601 - 700 of 1162 matches
Mail list logo