# Force\_https not working with GCP Ingress

**URL:** <https://meta.discourse.org/t/force-https-not-working-with-gcp-ingress/130593>\
**Category:** Product Support\
**Tags:** unsupported-install\
**Created:** [October 9, 2019, 5:16pm UTC](https://meta.discourse.org/t/force-https-not-working-with-gcp-ingress/130593 "2019-10-09T17:16:37Z")\
**Posts on this page:** 1\
**Showing post:** 1

<div class="post-metadata">

**Author:** ![pfaffman](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/pfaffman/32/120154_2.png) [@pfaffman](https://meta.discourse.org/u/pfaffman)\
**Post date:** [October 9, 2019, 5:16pm UTC](https://meta.discourse.org/t/force-https-not-working-with-gcp-ingress/130593/1 "2019-10-09T17:16:37Z")

</div>

I’ve got a kubernetes instance on GCP. Everything seems fine, but somehow `force_https` isn’t forcing a redirect and the sill can be retrieved on `http://`.

My solution for now has been to add this stanza to `app.yml`.

```plaintext
    - replace:
        filename: /etc/nginx/conf.d/discourse.conf
        from: ' add_header ETag "";'
        to: |
                  add_header ETag "";
                  if ($thescheme = "http") {
                    return 301 https://$host$request_uri;
                  }

```

(And I’d love to understand how to get `pups` to indent those lines I inserted, but I digress.)

Sometime after that change the ingres controller appears to have stopped serving the site, though it seemed to have been working–and properly redirecting–for at least a while.

Obviously this is #unsupported-install, but if anyone has an idea where to look next, I’d appreciate it.

---

_[View the full topic](https://meta.discourse.org/t/force-https-not-working-with-gcp-ingress/130593)._
