Mailing List Archive

[Bricolage #178] SFTP publishing does not work if a port is not supplied.
// Add your reply above here
==================================================
Nick Legg updated this ticket at January 17th, 2011 @ 07:25 PM

I can confirm this issue using the Bric 2.0 VMWare image found here: http://www.gossamer-threads.com/lists/bricolage/users/39465?search_string=vmware;#39465

I set up a publish destination to 'publish.example.com' but did not provide a port number, then received the following error on publish:

An error occurred while processing your request:

Unable to login to remote server 'publish.example.com'.

Net::SSH2: failed to connect to publish.example.com:: Invalid argument at /usr/local/bricolage/lib/Bric/Util/Trans/SFTP.pm line 139

View Error Details
Error Details (hide)

Fault Class
Bric::Util::Fault::Exception::GEN
Description
General Exception
Timestamp
2011-01-17 11:09:20.000000
Package
Bric::Util::Trans::SFTP
Filename
/usr/local/bricolage/lib/Bric/Util/Trans/SFTP.pm
Line
146

Stack:

Trace begun at /usr/local/bricolage/lib/Bric/Util/Trans/SFTP.pm line 146
Bric::Util::Trans::SFTP::put_res('Bric::Util::Trans::SFTP', 'ARRAY(0x7f2f5003f0c0)', 'Bric::Dist::ServerType=HASH(0x7f2f50022fe8)') called at /usr/local/bricolage/lib/Bric/Dist/Action/Mover.pm line 160
Bric::Dist::Action::Mover::do_it('Bric::Dist::Action::Mover=HASH(0x7f2f4fd21610)', 'ARRAY(0x7f2f5003f0c0)', 'Bric::Dist::ServerType=HASH(0x7f2f50022fe8)') called at /usr/local/bricolage/lib/Bric/Util/Job/Dist.pm line 227
Bric::Util::Job::Dist::_do_it('Bric::Util::Job::Dist=HASH(0x7f2f5001ee08)') called at /usr/local/bricolage/lib/Bric/Util/Job.pm line 1881
eval {...} at /usr/local/bricolage/lib/Bric/Util/Job.pm line 1879
Bric::Util::Job::execute_me('Bric::Util::Job::Dist=HASH(0x7f2f5001ee08)') called at /usr/local/bricolage/lib/Bric/Util/Job.pm line 1800
Bric::Util::Job::save('Bric::Util::Job::Dist=HASH(0x7f2f5001ee08)') called at /usr/local/bricolage/lib/Bric/Util/Burner.pm line 1350
Bric::Util::Burner::publish('Bric::Util::Burner=HASH(0x7f2f50011568)', 'Bric::Biz::Asset::Business::Story=HASH(0x7f2f4ffb8408)', 'story', 0, '2011-01-17 11:09:20.000000', 1) called at /usr/local/bricolage/lib/Bric/Util/Job/Pub.pm line 187
Bric::Util::Job::Pub::_do_it('Bric::Util::Job::Pub=HASH(0x7f2f4ffc1180)') called at /usr/local/bricolage/lib/Bric/Util/Job.pm line 1881
eval {...} at /usr/local/bricolage/lib/Bric/Util/Job.pm line 1879
Bric::Util::Job::execute_me('Bric::Util::Job::Pub=HASH(0x7f2f4ffc1180)') called at /usr/local/bricolage/lib/Bric/Util/Job.pm line 1800
Bric::Util::Job::save('Bric::Util::Job::Pub=HASH(0x7f2f4ffc1180)') called at /usr/local/bricolage/lib/Bric/App/Callback/Publish.pm line 184
Bric::App::Callback::Publish::publish('Bric::App::Callback::Publish=HASH(0x7f2f4ffbe8a0)') called at /usr/local/bricolage/lib/Bric/App/Callback/Desk.pm line 407
Bric::App::Callback::Desk::publish('Bric::App::Callback::Desk=HASH(0x7f2f4fee9740)') called at /usr/local/bricolage/lib/Bric/App/Callback/Profile/Story.pm line 224
Bric::App::Callback::Profile::Story::checkin('Bric::App::Callback::Profile::Story=HASH(0x7f2f4fee9ea8)') called at /usr/local/share/perl/5.10.1/Params/CallbackRequest.pm line 296
eval {...} at /usr/local/share/perl/5.10.1/Params/CallbackRequest.pm line 286
Params::CallbackRequest::request('Params::CallbackRequest=HASH(0x7f2f4c3a0ab0)', 'HASH(0x7f2f4cedcf30)', 'requester', 'MasonX::Interp::WithCallbacks=HASH(0x7f2f4eb50660)', 'apache_req', 'Apache2::Request=SCALAR(0x7f2f4fcb67c8)') called at /usr/local/share/perl/5.10.1/MasonX/Interp/WithCallbacks.pm line 119
MasonX::Interp::WithCallbacks::make_request('MasonX::Interp::WithCallbacks=HASH(0x7f2f4eb50660)', 'comp', '/workflow/profile/story/1024', 'args', 'ARRAY(0x7f2f4fc92428)', 'ah', 'HTML::Mason::ApacheHandler=HASH(0x7f2f4eb42278)', 'apache_req', 'Apache2::Request=SCALAR(0x7f2f4fcb67c8)') called at /usr/local/share/perl/5.10.1/HTML/Mason/ApacheHandler.pm line 868
eval {...} at /usr/local/share/perl/5.10.1/HTML/Mason/ApacheHandler.pm line 867
HTML::Mason::ApacheHandler::prepare_request('HTML::Mason::ApacheHandler=HASH(0x7f2f4eb42278)', 'Apache2::RequestRec=SCALAR(0x7f2f4fcfe3f8)') called at /usr/local/share/perl/5.10.1/HTML/Mason/ApacheHandler.pm line 822
HTML::Mason::ApacheHandler::handle_request('HTML::Mason::ApacheHandler=HASH(0x7f2f4eb42278)', 'Apache2::RequestRec=SCALAR(0x7f2f4fcfe3f8)') called at /usr/local/bricolage/lib/Bric/App/Handler.pm line 307
eval {...} at /usr/local/bricolage/lib/Bric/App/Handler.pm line 296
Bric::App::Handler::handler('Apache2::RequestRec=SCALAR(0x7f2f4fcfe3f8)') called at -e line 0
eval {...} at -e line 0

The story did not actually publish, but the database and interface both report that it did. The version was incremented and publish flag is set. I believe this particular behavior was reported and fixed here: http://bricolage.lighthouseapp.com/projects/29601/tickets/200.

Adding ':22' to the server address allows the publish to continue, but it ultimately fails to distribute properly. I received the following file output in my file system:
/\i\n\d\e\x\.\h\t\m\l\.tmp
Where I should have:
/index.html
--------------------------------------------------------------------------------

Assigned: Bugs (at bricolage)
State: new
Milestone: 2.0.1
View this ticket online: http://bricolage.lighthouseapp.com/projects/29601/tickets/178-sftp-publishing-does-not-work-if-a-port-is-not-supplied

Stop being notified of this ticket's changes: http://bricolage.lighthouseapp.com/projects/29601/tickets/178-sftp-publishing-does-not-work-if-a-port-is-not-supplied/watch
Update your Profile: http://bricolage.lighthouseapp.com/profile
Support: support@lighthouseapp.com or http://help.lighthouseapp.com
[Bricolage #178] SFTP publishing does not work if a port is not supplied. [ In reply to ]
// Add your reply above here
==================================================
Nick Legg updated this ticket at January 17th, 2011 @ 08:32 PM

Update: The VMWare image mentioned above was running code from the v2.0.0 tag (https://github.com/bricoleurs/bricolage/tree/v2.0.0).

I updated our VM instance to use lib/Bric/Util/Trans/SFTP.pm from the rev-2.0 branch (https://github.com/bricoleurs/bricolage/tree/rev-2.0), which was very different from the code found in v2.0.0. Unfortunately this version of SFTP.pm contained a few typos (put_res() and del_res() were calling "_connect()" instead of "_connect_to()", but the "missing port error" was otherwise absent.

Finally, I updated our VM instance to use SFTP.pm from the master branch which lacked the aforementioned typos. It worked! The file(s) published and distributed properly.

It looks like this issue was fixed in master around July 6 - July 9 2010, starting with this commit: https://github.com/bricoleurs/bricolage/blob/256e5509a54adb83253e190be26f948ca741efd1/lib/Bric/Util/Trans/SFTP.pm.
--------------------------------------------------------------------------------

Assigned: Bugs (at bricolage)
State: new
Milestone: 2.0.1
View this ticket online: http://bricolage.lighthouseapp.com/projects/29601/tickets/178-sftp-publishing-does-not-work-if-a-port-is-not-supplied

Stop being notified of this ticket's changes: http://bricolage.lighthouseapp.com/projects/29601/tickets/178-sftp-publishing-does-not-work-if-a-port-is-not-supplied/watch
Update your Profile: http://bricolage.lighthouseapp.com/profile
Support: support@lighthouseapp.com or http://help.lighthouseapp.com
[Bricolage #178] SFTP publishing does not work if a port is not supplied. [ In reply to ]
// Add your reply above here
==================================================
theory updated this ticket at January 17th, 2011 @ 08:36 PM
* Assigned user changed from "Bugs (at bricolage)" to "theory"
Thanks Nick. Can you fix the calls to _connect_to in rev-2.0?
--------------------------------------------------------------------------------

Assigned: theory
State: new
Milestone: 2.0.1
View this ticket online: http://bricolage.lighthouseapp.com/projects/29601/tickets/178-sftp-publishing-does-not-work-if-a-port-is-not-supplied

Stop being notified of this ticket's changes: http://bricolage.lighthouseapp.com/projects/29601/tickets/178-sftp-publishing-does-not-work-if-a-port-is-not-supplied/watch
Update your Profile: http://bricolage.lighthouseapp.com/profile
Support: support@lighthouseapp.com or http://help.lighthouseapp.com
[Bricolage #178] SFTP publishing does not work if a port is not supplied. [ In reply to ]
// Add your reply above here
==================================================
theory updated this ticket at January 17th, 2011 @ 09:13 PM
* State changed from "new" to "resolved"
he did. See it [here](https://github.com/bricoleurs/bricolage/commit/11ca5ab49c7878cd24ff82157a159e7bee3ad9d1). Woot!
--------------------------------------------------------------------------------

Assigned: theory
State: resolved
Milestone: 2.0.1
View this ticket online: http://bricolage.lighthouseapp.com/projects/29601/tickets/178-sftp-publishing-does-not-work-if-a-port-is-not-supplied

Stop being notified of this ticket's changes: http://bricolage.lighthouseapp.com/projects/29601/tickets/178-sftp-publishing-does-not-work-if-a-port-is-not-supplied/watch
Update your Profile: http://bricolage.lighthouseapp.com/profile
Support: support@lighthouseapp.com or http://help.lighthouseapp.com