# HTTP to HTTP configuration problem

**URL:** <https://community.passbolt.com/t/http-to-http-configuration-problem/4292>\
**Category:** Installation Issues\
**Created:** [October 6, 2021, 11:52am UTC](https://community.passbolt.com/t/http-to-http-configuration-problem/4292 "2021-10-06T11:52:14Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![solaire](https://yyz1.discourse-cdn.com/flex031/user_avatar/community.passbolt.com/solaire/32/1718_2.png) [@solaire](https://community.passbolt.com/u/solaire)\
**Post date:** [October 6, 2021, 11:52am UTC](https://community.passbolt.com/t/http-to-http-configuration-problem/4292/1 "2021-10-06T11:52:14Z")

</div>

**Checklist**  
[x] I have read intro post: [About the Installation Issues category](https://community.passbolt.com/t/about-the-installation-issues-category/12)  
[x] I have read the tutorials, help and searched for similar issues  
[x] I provide relevant information about my server (component names and versions, etc.)  
[x] I provide a copy of my logs and healthcheck  
[x] I describe the steps I have taken to trouble shoot the problem  
[x] I describe the steps on how to reproduce the issue

Hi,

**Description:**  
I have a question about redirecting from HTTP to HTTPS.  
If I’m using [https://passbolt.domain.com](https://passbolt.domain.com) it works correctly but if I type in browser “passbolt.domain.fun”  
it does not redirect to HTTPS.

**Domain and certificate:**

- I have my own certificate and domain.

**Passbolt version and environment:**

- Docker container
- Version: 3.2.1-2-ce-non-root

**What I’ve done:**

- Installed Passbolt docker image
- In the folder **/etc/ssl/certs** I’ve copied my certificate and key
- Restart the docker container

Probably this is a configuration issue (from my side) but I cannot found any answers on how to configure it properly.

So, my questions are:

1. Where passbolt stores configuration for nginx inside the docker container?
2. Do I have to change ngxinx configuration to be able to redirect from HTTP to HTTPS?

Also, I’ve tried to use this: [Passbolt Help | Manual HTTPS configuration on Debian and Ubuntu with user provided certificates](https://help.passbolt.com/configure/https/ce/debian/manual.html)  
but it does not help me.

---

<div class="post-metadata">

**Author:** ![AnatomicJC](https://yyz1.discourse-cdn.com/flex031/user_avatar/community.passbolt.com/anatomicjc/32/962_2.png) [@AnatomicJC](https://community.passbolt.com/u/AnatomicJC)\
**Post date:** [October 6, 2021, 6:43pm UTC](https://community.passbolt.com/t/http-to-http-configuration-problem/4292/2 "2021-10-06T18:43:53Z")

</div>

Hi @solaire,

You’re right, I got the same issue, and only with docker. If you have a look at the browser debug console, it seems related to some CORS issue:

 ![image](https://canada1.discourse-cdn.com/flex031/uploads/passbolt/original/1X/19d2f7da20bc56dda2cf4654ae8ef00f013e6560.png)  
 ![image](https://canada1.discourse-cdn.com/flex031/uploads/passbolt/original/1X/5e94fe82c7d01dd1aabf4c787bf0ec8ce2ffca74.png)

While waiting this to be fixed, you can edit and bind mount a modified version of /etc/nginx/snippets/passbolt-ssl.conf file by adding this somewhere in the file content:

```auto
  if ($scheme = http) {
    return 301 https://$host$request_uri;
  }

```

Thus, if http scheme is detected, your request will be redirected to its https version 🙂

---

<div class="post-metadata">

**Author:** ![solaire](https://yyz1.discourse-cdn.com/flex031/user_avatar/community.passbolt.com/solaire/32/1718_2.png) [@solaire](https://community.passbolt.com/u/solaire)\
**Post date:** [October 6, 2021, 6:58pm UTC](https://community.passbolt.com/t/http-to-http-configuration-problem/4292/3 "2021-10-06T18:58:45Z")

</div>

@AnatomicJC Fantastic!

This is what I’ve needed 🙂

Thank you 🙂
