[Israel.pm] web-based script
Yuval Yaari
yuval at windax.com
Tue Aug 31 05:30:07 PDT 2004
Shlomo Yona said:
> On Tue, 31 Aug 2004, Yuval Yaari wrote:
>
>> This can all be done from the shell.
>> And as much as I like to write Perl -- I'd rather use already-written
>> tools.
>>
>>> [in the browser]
>>> * goto url x.y.z
>>> * login (username+password) [1]
>>
>> This can be done with wget and/or lwp-request and/or curl.
>
> I was hoping for a snippet...
> I guess I'll RTFM...
wget --http-user=abc and --http-pass=xyz? I can't recall...
Maybe later when I get home :)
[Snip]
>> Can you emulate this by hacking the URL?
>> Otherwise you can use WWW::Mechanize (which means you will write code,
>> but it's easy).
>
> No. It is all based on POST.
I assume lwp-request/wget can send POST data.
WWW::Mechanize is very simple and gets things done.
>
>>> <wait for a download of a HUGE (over 100 mg) file>
>
> I anticipate problems here due to time-outs.
> How can this be controlled?
Didn't you just say you'll RTFM? :)
Sorry, I never tried to change time-out values.
But I actually don't think you'd have a problem with it.
[Snip]
>> Rsync runs over SSH, and can be used with SSH keys.
>
> Don't I need a Rsync server at the other end? If I do...
> then I'm screwed because there isn't one...
I'll rephrase:
rsync CAN run over SSH (probably works like scp does, but I wouldn't know).
No rsyncd is needed.
Anyway, would setting up rsyncd cause a problem?
>> That means you can sync the directory, run scripts, chmod, etc.
>> I wrote a backup script for my former company that backs things up
>> over SSH using rsync and also chmods stuff.
>>
>
> I might email you with some queries then...
Go ahead.
I might even still have some code at home...
--Yuval
More information about the Perl
mailing list