3

I need to send a single binary file to a couple of IoTs. It wants a URL where it can download this file.

www.somekindadomain.aaa/binaryfile

I tried, GDrive, OneDrive, Droplr and a couple of others and they all take you to a landing page where you can click a link to download the file.

My IoTs do not have any way to click a link to get the file.

I tried getting it to work via GitHub and I was not able to get a unique URL for the raw file (this may be my fault).

Does anyone know of a super easy way to have a URL (no credentials required (again due to IoT) simply point direct to a file and when the url is hit, it just shoves the file out.

I must be missing something.

I have no bought a $1 domain so I can host it and do it myself from a webserver I control (I hope).

What am I missing?

Destroy666
  • 5,299
  • 7
  • 16
  • 35
  • 2
    We don't know what you are missing, because we don't know what exactly you do to share the file. In the case of the Github solution, you don't even say what the problem is. I just uploaded a PDF to a Github repo, right-clicked on it and copied the URL. Then I downloaded it to my PC with curl. No credentials. – berndbausch Jul 23 '21 at 14:02
  • Do these "IoTs" **need** to download the file from the internet? If they are all on your local network then you could set up a tiny web server such as http://tinyserver.sourceforge.net/ and then point the devices at `http://192.168.0.24/binary` ... or whatever the IP address of your device is. Or you could use port forwarding on your router to open it up and make your web server accessible via your public IP. The reason all these "file sharing" services use landing pages is precisely because they want them to be used by *humans* not as an automated update service for every device on the planet – Mokubai Jul 23 '21 at 14:21
  • @berndbausch I have no problem doing it with GitHub in file formats that GitHub knows. I was not able to do with an unknown binary format – Coding A Hippo Jul 23 '21 at 17:08
  • You are right. It's not that easy to share binary files on Github. Probably a feature, not a bug - Github doesn't want to be a service for sharing dubious content. I am glad you found an object storage solution. – berndbausch Jul 24 '21 at 03:30
  • If you have a solution that works for you then you should post it as an answer, not as an edit to your question. Then you will be able to accept your answer an mark your question as solved. – Mokubai Jul 25 '21 at 02:21

1 Answers1

1

Drop it in the public-facing folder on your hosting (the main web folder). http://domain/binary-file.bin. Done.

If you want simple password protection, ensure your hosting has ftp enabled and: ftp://username:password@domain/binary-file.bin

Note the password and user are stored in plain text in the above, which is easy to decrypt.

Yorik
  • 4,166
  • 1
  • 11
  • 16