Kad Kerforn
2008-May-29 12:23 UTC
rake SshFilePublisher on port different from standard 22
I am testing rake file upload, running well rcp in a terminal scp -v -P 666 -q /Users/kadoudal/musicians.xml kadoudal-3Q2Tfjf0mexWk0Htik3J/w@public.gmane.org:httpdocs/var/www/html/jazz_people but when running from the rake file publisher = Rake::SshFilePublisher.new( "kadoudal@ mydomain.com", "/httpdocs/var/www/html/jazz_people", File.dirname(__FILE__), t.prerequisites.first) publisher.upload I get an error, which quite normal as I should precise the port 666 how can I do it ? there is no publisher.option ? thanks for your help note : I also tried "kadoudal@ mydomain.com:666" as a host .. no way error Command failed with status (1): [scp -q ...... -- Posted via http://www.ruby-forum.com/. --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk-unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~----------~----~----~----~------~----~------~--~---
Kad Kerforn
2008-May-29 13:12 UTC
Re: rake SshFilePublisher on port different from standard 22
Kad Kerforn wrote:> I am testing rake file upload, running well rcp in a terminal > > scp -v -P 666 -q /Users/kadoudal/musicians.xml > kadoudal-3Q2Tfjf0mexWk0Htik3J/w@public.gmane.org:httpdocs/var/www/html/jazz_people > > but when running from the rake file > > publisher = Rake::SshFilePublisher.new( > "kadoudal@ mydomain.com", > "/httpdocs/var/www/html/jazz_people", > File.dirname(__FILE__), > t.prerequisites.first) > publisher.upload > > I get an error, which quite normal as I should precise the port 666 > > how can I do it ? there is no publisher.option ? > > thanks for your help > > note : I also tried "kadoudal@ mydomain.com:666" as a host .. no way > error > Command failed with status (1): [scp -q ......ok solved with a patch in gem rake/contrib/sshpublisher.rb # Upload the local directory to the remote directory on non-standard port def upload_port(port=22) @files.each do |fn| sh %{scp -P #{port} -q #{@local_dir}/#{fn} #{@host}:#{@remote_dir}} end end now I can do publisher.upload_port(666) -- Posted via http://www.ruby-forum.com/. --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk-unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~----------~----~----~----~------~----~------~--~---
Hassan Schroeder
2008-May-29 14:20 UTC
Re: rake SshFilePublisher on port different from standard 22
On Thu, May 29, 2008 at 6:12 AM, Kad Kerforn <rails-mailing-list-ARtvInVfO7ksV2N9l4h3zg@public.gmane.org> wrote:>> I get an error, which quite normal as I should precise the port 666 >> >> how can I do it ? there is no publisher.option ?You can also specify the port to use for a specific host in your own ~/.ssh/config file -- man ssh_config FWIW, -- Hassan Schroeder ------------------------ hassan.schroeder-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk-unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~----------~----~----~----~------~----~------~--~---
Kad Kerforn
2008-May-29 15:37 UTC
Re: rake SshFilePublisher on port different from standard 22
Hassan Schroeder wrote:> On Thu, May 29, 2008 at 6:12 AM, Kad Kerforn > <rails-mailing-list-ARtvInVfO7ksV2N9l4h3zg@public.gmane.org> wrote: > >>> I get an error, which quite normal as I should precise the port 666 >>> >>> how can I do it ? there is no publisher.option ? > > You can also specify the port to use for a specific host in your own > ~/.ssh/config file -- man ssh_config > > FWIW, > -- > Hassan Schroeder ------------------------ hassan.schroeder-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.orgyes, ok thank you I belive that''s the reason why it was not necessary it include it as an option got it... (it was my first test of it...) -- Posted via http://www.ruby-forum.com/. --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk-unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~----------~----~----~----~------~----~------~--~---