docker icon indicating copy to clipboard operation
docker copied to clipboard

为什么我使用https访问服务器,却有部分链接仍然使用的是http ?

Open kevinzu007 opened this issue 6 years ago • 3 comments

https://github.com/nextcloud/docker/blob/master/.examples/docker-compose/with-nginx-proxy-self-signed-ssl/mariadb/fpm/ 我使用上面这个docker-compose配置文件测试部署nextcloud,在客户端使用 https://nextcloud.zjlh.lan 访问nextcloud,发现下面这几个链接依然使用的是http,并不是https,为啥?

  1. http://nextcloud.zjlh.lan/apps/firstrunwizard/img/apps/tasks.svg
  2. http://nextcloud.zjlh.lan/apps/firstrunwizard/img/apps/deck.svg
  3. http://nextcloud.zjlh.lan/apps/firstrunwizard/img/apps/notes.svg
  4. http://nextcloud.zjlh.lan/apps/firstrunwizard/img/apps/social.svg
  5. http://nextcloud.zjlh.lan/apps/firstrunwizard/img/apps/groupfolders.svg image

会不会其他地方也有这个问题? 如果我不开启tcp 80端口,会不会造成使用故障?

kevinzu007 avatar Apr 20 '20 06:04 kevinzu007

https://github.com/nextcloud/docker#using-the-apache-image-behind-a-reverse-proxy-and-auto-configure-server-host-and-protocol?

kesselb avatar Apr 20 '20 19:04 kesselb

搞定,谢谢!

kevinzu007 avatar Apr 25 '20 05:04 kevinzu007

mark: docker-compose.yml中加了下面两行:

  - APACHE_DISABLE_REWRITE_IP=true
  - OVERWRITEPROTOCOL=https

kevinzu007 avatar Apr 25 '20 06:04 kevinzu007