title: Problem with Kibana login after set SERVER_BASEPATH SERVER_PUBLICBASEURL
body: <p>Hi I have configured kibana with SERVER_BASEPATH and SERVERPUBLICURL but I am receiving &quot;GET /api/licensing/info 401&quot; and the login page is refreshed and go back to login again</p>
  <p>Now I'm trying directly, but the idea is to keep kibana behind nginx proxy, but with proxy and without proxy neither works, this throw the same message error</p>
  <p>Here my docker kibana configuration</p>
  <pre class="lang-yaml prettyprint-override"><code>  #Kibana
    kib01:
      image: docker.elastic.co/kibana/kibana:7.16.0
      ports:
        - 9201:5601
      environment:
        ELASTICSEARCH_URL: http://es01:9200
        ELASTICSEARCH_HOSTS: '[&quot;http://es01:9200&quot;]' #,&quot;http://es02:9200&quot;]' #,&quot;http://es03:9200&quot;]'
        ELASTICSEARCH_USERNAME: elastic
        ELASTICSEARCH_PASSWORD: $ELASTIC_PASSWORD
        SERVER_BASEPATH: /dmckbnlog
        SERVER_PUBLICBASEURL: http://dmc.development.com:9201/dmckbnlog
        SERVER_REWRITEBASEPATH: 'true'
        SERVER_NAME: 
        extra_hosts: dmc.development.com
          - &quot;dmc.development.com:192.168.1.188&quot;
      volumes:
        - c:/data/kibana/kibana.yml:/usr/share/kibana/config/kibana.yml
  </code></pre>
  <p>kibana.yml</p>
  <pre class="lang-yaml prettyprint-override"><code>#
  # ** THIS IS AN AUTO-GENERATED FILE **
  #
  
  # Default Kibana configuration for docker target
  server.host: &quot;0.0.0.0&quot;
  server.shutdownTimeout: &quot;5s&quot;
  elasticsearch.hosts: [ &quot;http://elasticsearch:9200&quot; ]
  monitoring.ui.container.elasticsearch.enabled: true
  </code></pre>
  <p>Best regards</p>