Starting with CrushClient 1.8.0, it can also be run with a quick single command type action.
The following command actions can be used: copy, move, delete, rename, test.
After the command action you can specify parameters, then finally you can specify the urls. So the syntax is always as follows:
java -jar CrushTunnel.jar COMMAND_ACTION [-o | -c | -lc] SRC_URL DEST_URL
-o parameter is for overall options on the CrushClient.
-c parameter is for connection specific configurations for the destination location
-lc parameter is for connection specific configurations for the source location (not commonly used)
-v parameter makes the output a bit more verbose
Please note the spacing on -o and -c parameters. There is NOT a space between the parameter, equals sign, and value. Adding a space will break the syntax and everything will fail.
An upload uses a local path as the first source location where a download uses the server url as the first source location. To prompt for a password instead of including it, use the password of "-ASK-" and the console will wait for you to enter it.
java -jar CrushTunnel.jar copy file://folder1/file.txt https://user:pass@server.com/ java -jar CrushTunnel.jar copy file://folder1/file.txt https://user:pass@server.com/file_new_name.txt java -jar CrushTunnel.jar copy /C:/folder1/file.txt https://user:pass@server.com/file_new_name.txt java -jar CrushTunnel.jar copy https://user:pass@server.com/file.txt file://folder1/file.txt java -jar CrushTunnel.jar copy -o max_threads=10 -c ssh_private_key=/C:/keys/test.ppk sftp://user:pass@server.com:port/file.txt file://folder1/file.txt java -jar CrushTunnel.jar copy file://folder1/ https://user:pass@server.com/ java -jar CrushTunnel.jar move file://folder1/ https://user:pass@server.com/ java -jar CrushTunnel.jar delete https://user:pass@server.com/folder1/file.txt java -jar CrushTunnel.jar delete https://user:pass@server.com/folder1/ java -jar CrushTunnel.jar rename https://user:pass@server.com/folder1/file.txt file2.txt
If the command fails, the exit code will be non 0.
Some additional useful config parameters:
-c multi=true #(default=false) multi segmented uploads. -c ssh_private_key=/C:/keys/test.ppk -c ssh_private_key_pass=password #ssh private key and password -o segmented_transfer=false #(default=true) disabled faster http(s) transfers to CrushFTP servers -o max_threads=10 #default is 10 threads for when transferring a folder with many items -o keep_date=false #(default=true) don't preserve modified dates on file transfers -o skip_modified_and_size=false #(default=true) don't skip an upload even if the size and date matches -o skip_modified=true #(default=false) skip if the modified date is different -o skip_size=true #(default=false) skip if the size is different
Add new attachment
Only authorized users are allowed to upload new attachments.
«
This particular version was published on 08-Nov-2021 07:41 by Ben Spink.
G’day (anonymous guest)
Log in
JSPWiki