I am trying to run this curl request that is running successfully from my terminal in python:
curl -vvv -u <user>:<password> --upload-file filePath.zip http:/someHostostName:port/pathInNexus
in python i wrote:
import requests
files = {'file': open("filePath.zip", 'rb')}
url = "http:/someHostostName:port/pathInNexus"
response = requests.post(url,files = files ,auth=(<user>, <password>)
and I'm getting this error:
HTTPConnectionPool(host='ilcebln005.corp.amdocs.com', port=8081): Max retries exceeded with url: pathInNexus (Caused by NewConnectionError('<urllib3.connection.HTTPConnection object at 0x000001C2715A7CC8>: Failed to establish a new connection: [WinError 10061] No connection could be made because the target machine actively refused it'))
I'm fairly new to curl requests and im trying to automate it at Python