La operación CURL falló

La operación CURL falló

Quiero hacer esta carga a mi servidor:

curl -u ****:**** -T - sftp://*****.com:22/apps/jboss-5.1.0/server/fab_server/deploy -v -k

El problema es que recibo este error:

% Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
  0     0    0     0    0     0      0      0 --:--:-- --:--:-- --:--:--     0* About to connect() to ****.com port 22 (#0)
*   Trying ****...
* Connected to ****.com (****) port 22 (#0)
* SSH MD5 fingerprint: ****
* SSH authentication methods available: publickey,password,keyboard-interactive
* Using ssh public key file /home/****/.ssh/id_dsa.pub
* Using ssh private key file /home/****/.ssh/id_dsa
* SSH public key authentication failed: Unable to open public key file
* Initialized password authentication
* Authentication complete
* Upload failed: Operation failed (4/-31)
  0     0    0     0    0     0      0      0 --:--:-- --:--:-- --:--:--     0
  0     0    0     0    0     0      0      0 --:--:-- --:--:-- --:--:--     0
* Connection #0 to host ****.com left intact
curl: (79) Upload failed: Operation failed (4/-31)

¿Alguien sabe cómo arreglarlo?

Respuesta1

Resolví el problema; Tuve que especificar el nombre del archivo de destino.

Respuesta2

Resolví el mismo tipo de problema agregando un carácter "/" en la ruta del directorio de destino, así:

curl --insecure --user ****:**** -T ./sourcefile.txt sftp://DestinationIP/directory/

información relacionada