Uploading Files Using cURL

To upload a file perform the following steps:

1. Create an SSH connection to the Unix server where the file is located.

2. Type the following string in the Unix shell:

curl -k -F myfile=@install.log -H 'HTTP_AUTH_LOGIN:admin' -H 'HTTP_AUTH_PASSWD:password' https://<em>panel-ip</em>:8443/enterprise/control/agent.php

 

Arguments

curl

 

 

Specifies that cURL is used. You need to install it to the Unix machine.

-k

 

 

The SSL connection is used.

-F myfile=@install.log

 

 

The install.log file is to be uploaded. You can upload multiple files in a single packet.

-H 'HTTP_AUTH_LOGIN:admin'

 

 

Specifies the login of the Panel administrator. Substitute the admin value by your login to the Panel.

-H 'HTTP_AUTH_PASSWD:password'

 

 

Specifies the Panel administrator's password. Substitute your password for access to the Panel for the password value.

https://panel-ip:8443/enterprise/control/agent.php

 

 

Specifies the Panel server address. Substitute the <panel-ip> value with the IP address of the server.

3. Press ENTER.