# Https file server on nodered+IBM cloud

**URL:** https://discourse.nodered.org/t/https-file-server-on-nodered-ibm-cloud/20432
**Category:** General
**Created:** [16 January 2020 08:22 UTC](https://discourse.nodered.org/t/https-file-server-on-nodered-ibm-cloud/20432 "2020-01-16T08:22:54Z")
**Posts on this page:** 4
**Page:** 1

<div class="post-metadata">

### Author: ![etawyy](https://avatars.discourse-cdn.com/v4/letter/e/7bcc69/32.png) [@etawyy](https://discourse.nodered.org/u/etawyy)
#### Post date: [16 January 2020 08:22 UTC](https://discourse.nodered.org/t/https-file-server-on-nodered-ibm-cloud/20432/1 "2020-01-16T08:22:54Z")

</div>

Hi there,  
I need to setup a https file server, used by my iot objects to fetch their updated firmware.  
I have a node-red app, (note: on IBM cloud) so the easiest for me would be to use that.

On http that works fine: "http in" node + "file edit in" node + modify headers and response node.

Can anyone help me turn this into https ?

---

<div class="post-metadata">

### Author: ![knolleary](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/knolleary/32/3_2.png) [@knolleary](https://discourse.nodered.org/u/knolleary)
#### Post date: [16 January 2020 09:13 UTC](https://discourse.nodered.org/t/https-file-server-on-nodered-ibm-cloud/20432/2 "2020-01-16T09:13:39Z")

</div>

@etawyy Node-RED provides a setting called `httpStatic` that can be used to point at a directory of static content it should serve. The default configuration for Node-RED running on IBM Cloud already [has that set](https://github.com/ibmets/node-red-bluemix-starter/blob/master/bluemix-settings.js#L64) - which is what serves up the landing page you get when you go to your app's url.

So rather than create individual HTTP In flows, if you add the files to the `public` directory of your app, then they will be served automatically.

There is also an option you can add to your `bluemix-settings.js` file to force it to redirect any http request to https. You need to add:

```auto
requireHttps: true,

```

into the settings file - add it below the `httpStatic` line.

---

<div class="post-metadata">

### Author: ![etawyy](https://avatars.discourse-cdn.com/v4/letter/e/7bcc69/32.png) [@etawyy](https://discourse.nodered.org/u/etawyy)
#### Post date: [16 January 2020 11:10 UTC](https://discourse.nodered.org/t/https-file-server-on-nodered-ibm-cloud/20432/3 "2020-01-16T11:10:47Z")

</div>

Thanks Nick. This was easy. I have done what you suggested and it works with a web browser.

Now my IOT object librairy requires that I use a certificate.

I need to figure that part out on IBM cloud now... The management of the certificate should be done at IBM cloud level ("domain management") or inside node-red?

---

<div class="post-metadata">

### Author: ![knolleary](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/knolleary/32/3_2.png) [@knolleary](https://discourse.nodered.org/u/knolleary)
#### Post date: [16 January 2020 11:22 UTC](https://discourse.nodered.org/t/https-file-server-on-nodered-ibm-cloud/20432/4 "2020-01-16T11:22:16Z")

</div>

You'll have to do that at the IBM Cloud level.
