I am testing rake file upload, running well rcp in a terminal
scp -v -P 666 -q /Users/kadoudal/musicians.xml
[email protected]: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 …
Kad K. wrote:
I am testing rake file upload, running well rcp in a terminal
scp -v -P 666 -q /Users/kadoudal/musicians.xml
[email protected]: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)
On Thu, May 29, 2008 at 6:12 AM, Kad K.
[email protected] 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 S. ------------------------ [email protected]
Hassan S. wrote:
On Thu, May 29, 2008 at 6:12 AM, Kad K.
[email protected] 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 S. ------------------------ [email protected]
yes, 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…)