Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

In this use case YADE will transfer all the files present in the ${TEMP}/source directory on the localhost to the /home/test/inbound directory on the FTP server.
The FTP server settings are defined in the KeePassX database keepassX-test.kdb in an entry with the title sos/server/mp.sos.

...

YADE profile

Code Block
languagebash
[copy_localhost2server_with_cs]
file_spec                         = .*
operation                         = copy
verbose                           = 9
;;
source_protocol                   = local
source_host                       = localhost
source_dir                        = $\{TEMP\}/source
source_make_dirs                  = true
;;
target_use_credential_Store       = true
target_CredentialStore_FileName   = C:\Program Files\sos-berlin.com\jobscheduler.1.6.4043\djsmp02_4445\examples\keepassX-test.kdb
target_CredentialStore_password   = testing
target_CredentialStore_KeyPath    = sos/server/mp.sos
;;
target_dir                        = /home/test/inbound
target_make_dirs                  = true
target_protocol                   = ftp
target_transfer_mode              = ascii

...

Copy from FTP server to localhost

YADE profile

Code Block
languagebash
[copy_server2localhost_with_cs]
file_spec                         = .*
operation                         = copy
verbose                           = 9
;;
source_use_credential_Store       = true
source_CredentialStore_FileName   = C:\Program Files\sos-berlin.com\jobscheduler.1.6.4043\djsmp02_4445\examples\keepassX-test.kdb
source_CredentialStore_password   = testing
source_CredentialStore_KeyPath    = sos/server/homer2.sos
;;
source_dir                     = /home/test/outbound
source_make_dirs               = true
source_protocol                = ftp
source_transfer_mode           = ascii
;;
target_protocol                = local
target_host                    = localhost
target_dir                     = $\{TEMP\}/target
target_make_dirs               = true

...

In this use case YADE will transfer all the files from the /home/test/outbound directory on server homer2 to the /home/test/inbound directory on server mp.sos.

YADE profile

Code Block
languagebash
[copy_p2p_with_cs]
file_spec                         = .*
operation                         = copy
verbose                           = 9
;;
source_use_credential_Store       = true
source_CredentialStore_FileName   = C:\Program Files\sos-berlin.com\jobscheduler.1.6.4043\djsmp02_4445\examples\keepassX-test.kdb
source_CredentialStore_password   = testing
source_CredentialStore_KeyPath    = sos/server/homer2.sos
source_dir                        = /home/test/outbound
source_make_dirs                  = true
source_protocol                   = ftp
source_transfer_mode              = ascii
;;
target_use_credential_Store       = true
target_CredentialStore_FileName   = C:\Program Files\sos-berlin.com\jobscheduler.1.6.4043\djsmp02_4445\examples\keepassX-test.kdb
target_CredentialStore_password   = testing
target_CredentialStore_KeyPath    = sos/server/mp.sos
target_dir                        = /home/test/inbound
target_make_Dirs                  = true
target_protocol                   = ftp
target_transfer_mode              = ascii

...

For the SFTP protocol the YADE can either use password authentication or private/public key authentication.
The SFTP authentication method can be specifed using the parameters source_ssh_auth_method resp. target_ssh_auth_method  and the values password or publickey

YADE profile

Code Block
languagebash
[copy_localhost2SftpServer_with_cs]
file_spec                         = .*
operation                         = copy
verbose                           = 9
;;
source_protocol                   = local
source_host                       = localhost
source_dir                        = ${TEMP}/source
source_make_dirs                  = true
;;
target_use_credential_Store       = true
target_CredentialStore_FileName   = C:\Program Files\sos-berlin.com\jobscheduler.1.6.4043\djsmp02_4445\examples\keepassX-test.kdb
target_CredentialStore_password   = testing
target_CredentialStore_KeyPath    = sos/server/sftp_homer.sos
;;
target_protocol                   = sftp
target_dir                        = /home/test/inbound
target_ssh_auth_method            = password
target_make_dirs                  = true
target_transfer_mode              = ascii

...