diff --git a/agent/app/service/website_proxy.go b/agent/app/service/website_proxy.go index 3dc629cb2d2f..6016280299c4 100644 --- a/agent/app/service/website_proxy.go +++ b/agent/app/service/website_proxy.go @@ -117,8 +117,10 @@ func (w WebsiteService) OperateProxy(req request.WebsiteProxyConfig) (err error) applyLocationProxyPass(location, req.ProxyPass, &req.SNI, req.ProxySSLName) if isHTTPSProxyPass(req.ProxyPass) && req.SSLVerify { location.UpdateDirective("proxy_ssl_verify", []string{"on"}) + location.UpdateDirective("proxy_ssl_trusted_certificate", []string{"/etc/ssl/certs/ca-certificates.crt"}) } else { location.RemoveDirective("proxy_ssl_verify", []string{}) + location.RemoveDirective("proxy_ssl_trusted_certificate", []string{}) } location.UpdateDirective("proxy_set_header", []string{"Host", req.ProxyHost}) location.ChangePath(req.Modifier, req.Match)