We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent ed9b615 commit 37d2db4Copy full SHA for 37d2db4
plugins/modules/iso.py
@@ -125,6 +125,7 @@ def ensure_present(module, rest_client):
125
TaskTag.wait_task(rest_client, task_tag_create)
126
127
# Uploading ISO image.
128
+ file_size = os.stat(module.params["source"]).st_size
129
with open(module.params["source"], "rb") as source_file:
130
rest_client.put_record(
131
endpoint="/rest/v1/ISO/%s/data" % iso_uuid,
@@ -135,6 +136,7 @@ def ensure_present(module, rest_client):
135
136
headers={
137
"Content-Type": "application/octet-stream",
138
"Accept": "application/json",
139
+ "Content-Length": file_size,
140
},
141
)
142
0 commit comments