recherche

Maison  >  Questions et réponses  >  le corps du texte

php - Comment configurer 8080 pour l'intégration Linux Nginx+Tomcat?

location ~ .*.jsp$ { # Correspond aux fichiers se terminant par jsp. Les fichiers de la page Web de Tomcat se terminent par jsp.
                index index.jsp;
                proxy_pass http://127.0.0.1:8080; #Configurez principalement un proxy ici
        

127.0.0.1:8080 est-il ici comme ceci ou le nom de domaine réel ? Par exemple, http://www.xxx.com:8080 ?

高洛峰高洛峰2838 Il y a quelques jours422

répondre à tous(1)je répondrai

  • 巴扎黑

    巴扎黑2017-05-16 13:04:36

    Adresse d'accès : http://www.xxx.com La configuration est la suivante :

          server {
                    listen       80;
                    server_name  www.xxx.com;
    
                    access_log  logs/xxx.access.log  main;
    
                    location / {
                        root   html;
                        index  index.html index.htm;
                    }
                        
                    location ~ .*.jsp$ {     #匹配以jsp结尾的,tomcat的网页文件是以jsp结尾         
                        index index.jsp;
                        proxy_pass http://127.0.0.1:8080; #主要在这里,设置一个代理
                    }
            }
    }

    répondre
    0
  • Annulerrépondre