<p>I've tried other related solutions but I can't seem to get this working right and I'm sure it is just a namespacing issue or something because this is my first experience with using ConfigMaps, but can someone help me troubleshoot why this isn't working?</p>

<p>Here's my ingress:</p>

<pre><code>apiVersion: networking.k8s.io/v1beta1
kind: Ingress
metadata:
  name: brushfire-ingress
  labels:
    helm.sh/chart: brushfire-0.1.0
    app.kubernetes.io/name: brushfire
    app.kubernetes.io/instance: brushfire
    app.kubernetes.io/version: "1.16.0"
    app.kubernetes.io/managed-by: Helm
  annotations:
    cert-manager.io/cluster-issuer: brushfire-issuer
    kubernetes.io/ingress.class: nginx
    nginx.ingress.kubernetes.io/force-ssl-redirect: "true"
    nginx.ingress.kubernetes.io/rewrite-target: /$1
    nginx.ingress.kubernetes.io/ssl-redirect: "true"
spec:
  tls:
    - hosts:
        - "brushfire.online"
        - "*.brushfire.online"
      secretName: tls-secret
  rules:
    - host: "brushfire.online"
      http:
        paths:
          - path: /(.*)
            backend:
              serviceName: brushfire
              servicePort: 80
    - host: "*.brushfire.online"
      http:
        paths:
          - path: /(.*)
            backend:
              serviceName: brushfire
              servicePort: 80
</code></pre>

<p>And this is installed as part of a helm chart that is installed with <code>--namespace jorin-ssl</code></p>

<p>The ConfigMap I tried is:</p>

<pre><code>kind: ConfigMap
apiVersion: v1
metadata:
  labels:
    app: brushfire-ingress
  name: nginx-configuration
  namespace: ingress-nginx # I've also tried `jorin-ssl`
data:
  hsts: "false"
</code></pre>

<p>But in the end, the HSTS always appears to be there:</p>

<pre><code>$ curl -s -D- https://brushfire.online/ | grep -i Strict
</code></pre>

<p>returns</p>

<pre><code>strict-transport-security: max-age=15724800; includeSubDomains
</code></pre>

<p>For simplicity, I'd love to do this without using a ConfigMap at all. Is there not a way to do this with the annotations like we do with <code>force-ssl-redirect</code> etc?</p>

<p>The name of the <a href="https://kubernetes.github.io/ingress-nginx/user-guide/nginx-configuration/configmap/" rel="nofollow noreferrer">ConfigMap</a> must match what the nginx-ingress controller process is looking up. </p>

<p>The nginx-ingress process will use the <code>--configmap</code> argument on the command line to set the name. This option will be available in the container spec included in your deployment yaml.</p>

<p>For example, the helm deployment uses the <a href="https://github.com/helm/charts/blob/master/stable/nginx-ingress/templates/controller-deployment.yaml#L89" rel="nofollow noreferrer">full name of the controller</a> for the <code>--configmap</code> option.</p>
