Posted on 07-24-2018 08:20 AM
Hey JamfNation I am hoping someone can assist me here. We are using the jamf command setcomputername fromfile and I have a csv with 400+ entries of serials and computer names. I have uploaded the file to a webserver running iis7 and use
curl -O https://webserver/filename.csv
the file that gets outputted has zero bytes. What am I doing wrong here? PLEASE HELP!
for info the Mime type is set to application/octet-stream which is default for IIS and I have verified the permission on the file
Posted on 07-24-2018 08:34 AM
I've never used that kind of syntax with curl before. While technically it should work according to the man page, I would probably try something like this:
curl https://webserver/filename.csv -o /tmp/filename.csv
I'm not clear if you need to add any flags after curl, like a header or something else. You'll need to experiment with that. Also, I see that it's an https server. Do you need to provide authentication for it to work? Like -u username:password
perhaps?
Posted on 07-24-2018 08:42 AM
I could change the mime type to text/plain for CSV on your ISS server. Can you get it with a web browser with the same URL? What's in your ISS error log?
Posted on 07-24-2018 08:44 AM
I’m an idiot it’s an https site I was getting a 302 redirect all better now
Posted on 07-24-2018 08:45 AM
I had he command http 🤦♂️