Date: Wed, 16 May 2001 12:56:47 +0100 From: Alex Dyas <ADyas@twowaytv.com> To: freebsd-questions@FreeBSD.ORG Subject: RE: Scripting FTP actions Message-ID: <911D8F660DF6D411B61F00500462BA0171E235@exchange.twowaytv.co.uk>
next in thread | raw e-mail | index | archive | help
I ran into a similar situation recently with scripting FTP gets, solved it using command line ftp thus: <ftpscript.sh> #!/bin/sh # # Perform FTP ftp 10.10.10.10 2>&1 <<! bin cd /foo/bah/ get foo.bah /local/foo.bah ! </ftpscript.sh> Changing the get to put should work. This involves having the following .netrc file in the home directory of the user under which the script is being run: <.netrc> machine 10.10.10.10 login <username> password <password> </.netrc> Obviously as .netrc contains the username/password you need to be sure this is in a secure place. alex.. > -----Original Message----- > From: Tony Wells [mailto:awells@journalstar.com] > Sent: 15 May 2001 19:28 > To: freebsd-questions@FreeBSD.ORG > Subject: Scripting FTP actions > > > Hi all, > I need to be able to set up something where I can script a bunch of > FTP actions to send files to a remote server and I'm not sure where to > start looking. > > As far as a client I use ncftp, and looking at the man page I only see > "auto fetching" of files. > > Has anyone done this, or am I better off just writing a perl script > that pretends to be an FTP client? > > To Unsubscribe: send mail to majordomo@FreeBSD.org > with "unsubscribe freebsd-questions" in the body of the message > To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-questions" in the body of the message
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?911D8F660DF6D411B61F00500462BA0171E235>