In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-03-29 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Servers >
Share
Shulou(Shulou.com)05/31 Report--
This article focuses on "how to deploy a PHP application on an existing Java server". Interested friends may wish to take a look. The method introduced in this paper is simple, fast and practical. Let the editor take you to learn how to deploy a PHP application on an existing Java server.
First install the PHP environment, which pays attention to compatibility issues. Then there is the choice of PHP server, either Nginx or Apache.
If you use Nginx as a server, Nginx itself does not have the function of parsing PHP scripts, and you need to install php-fpm to parse PHP, then configure Nginx as a reverse proxy, and give the requested PHP script to php-fpm to parse. There are two ways to communicate between Nginx and php-fpm, either to configure a www.sock directly or to use tcp communication, the former needs to pay attention to permission issues.
If you use Apache as the server, there is not so much to do. The Apache server can handle the parsing of the PHP script on its own. We just need to put the PHP script in the correct location of the Apache server.
Since Nginx is already installed on the server, the first option is recommended.
This is probably the way of thinking. After that, the little friend went to do it on his own.
Two days later, the little friend came again, and the deployment was not successful. I tried all kinds of plans, encountered all kinds of BUG, and made a big deal. He asked me if I had any other good ideas.
I was too busy to help him troubleshoot, so I threw him a Docker order to try. A few minutes later, the buddy said, why didn't you say the Docker command earlier? it was so cool that it was done with one order.
To be honest, Docker really smells good. Especially in the current situation of hot cloud native technology, container technology, as an important part of cloud native technology, plays an extremely important role.
Brother Song started his exposure to container technology about three years ago, including Docker, Docker-Compose and later K8s. But to be honest, if you are just doing regular enterprise application development, there may not be many scenarios in which Docker is used at work, and the most common scenario is probably to install some environment. For operators, these are miraculous artifacts. Container technology greatly simplifies the workload of operation and maintenance. If the company has DevOps, you may see an operation and maintenance staff hanging around doing nothing all day, and then see that they are still carrying bricks painstakingly. People are more popular than people. Brother Song has a little friend who said more than once that he wanted to engage in operation and maintenance, and the development was too tired. After joining the DevOps, in most cases, the work of operation and maintenance is quite cool.
Now the MySql, Redis, RabbitMQ, MongoDB and so on on my Mac are all installed with Docker, which is convenient and easy to install. When you run out of it, you don't want it, and a command is deleted without leaving any trace.
At this point, I believe you have a deeper understanding of "how to deploy a PHP application on an existing Java server". You might as well do it in practice. Here is the website, more related content can enter the relevant channels to inquire, follow us, continue to learn!
Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.
Views: 0
*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.
Continue with the installation of the previous hadoop.First, install zookooper1. Decompress zookoope
"Every 5-10 years, there's a rare product, a really special, very unusual product that's the most un
© 2024 shulou.com SLNews company. All rights reserved.