通過Nginx代理Grafana,並通過域名訪問


通過Nginx代理Grafana,並通過域名訪問

配置nginx代理,nginx.conf增加如下並記得reload nginx

    location /monitor/ {
          proxy_pass http://Grafana_IP:PORT/;
    }

Grafana 配置文件修改

$ vim grafana/grafana.ini

domain = zongxiang.example.com 				# 你的訪問域名
root_url = %(protocol)s://%(domain)s:%(http_port)s/monitor/	# 代理localtion名(monitor)
  • 重啟Nginx Server
  • 重啟Grafana Server

瀏覽器訪問https://zongxiang.domain.com/即可打開Grafana頁面


免責聲明!

本站轉載的文章為個人學習借鑒使用,本站對版權不負任何法律責任。如果侵犯了您的隱私權益,請聯系本站郵箱yoyou2525@163.com刪除。



 
粵ICP備18138465號   © 2018-2025 CODEPRJ.COM