In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-01-19 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Development >
Share
Shulou(Shulou.com)06/01 Report--
Today, I will talk to you about how to deploy the php project remotely. Many people may not know much about it. In order to make you understand better, the editor has summarized the following for you. I hope you can get something from this article.
This article operating environment: Windows7 system, PHP7.1 version, DELL G3 computer
How to deploy a php project remotely?
Deploy the PHP project to the server
The project consists of a pile of php files that need to be connected to mysql
Process flow
Rent Server-> configure Environment-> Test php and Database Environment-> upload Files-> run
1. Rent a server
Steps:
Register and log in to Aliyun's official website-identity verification-student authentication-purchase-enter > console > CVM > instance-reset instance password-> configure environment
/
About the purchase
Ali Yun student opportunity: one month 10rmb
* but there is only one discount, so buy it for a few more months (sigh. Jpg
Region: you can choose more than one. It seems that the remaining server operating systems (inventory) are different in different regions.
Example: default 1CPU+2G
Operating system: Ubuntu 18.04 64-bit
* the operating system is Linux, so you can only copy other people's code crazily without Linux instructions.
/
About resetting password
No instance found: in the upper left corner of the page, select the region where the server you purchased is located
To remember the ip address, user name, and password, it is best to save it with a txt
/
two。 Configure the environment
Use the remote connection function that comes with the Ali Cloud platform
Steps:
(previous step)-Select Click to enter the purchased instance-remote connection drop-down Select workbench-Pop-up remote connection page-enter user name (default root) and password
* is there a password for a remote connection here? You need to set it yourself.
/
Configure environment specific instructions:
Reference: deploy the PHP project to the server so that others can see your results.
/
Hundreds of unexpected situations that have occurred
Unable to locate package: just update / change another instruction
The root directory var > www > html does not exist: create a new one yourself, and all project files will be placed here
Port: a port that adds mysql by itself
[more drop-down on the right side of the instance > Network and Security Group > configuration rules > manually add > Custom UDP purpose: 3306 Universe 3306 Source: 0.0.0.0amp 0]
* there are a lot of accidents that I forgot specifically.
/
3. test
Steps:
Test input ip address open-test php, mysql status
Test php and mysql are available and not available:
Put the php file phpInfo.php in the root directory [content is phpInfo ();]
Open http://ip address / phpInfo.php
4. Upload files on WINScp
Download winscp-connect with ip address, user name, password-upload files to\ var\ www\ html
(winscp uses tutorials to search by himself.)
* the directory opened by winscp by default is\ root. You need to return to the top directory\, and find\ var\ www\ html.
* generally,\ var already exists, but there is no\ var\ www. You can create a new www by yourself.
/
The database encountered a problem:
The connection to the mysql database here is through the http://ip address / phpmyadmin, which is different from the database tested locally.
Re-upload mysql table, data
Reset the username and password for phpmyadmin
Change the config of the project connection database (new user name and password)
What language is php php, a nested acronym, is the abbreviation of English Hypertext preprocessing language (PHP:Hypertext Preprocessor). PHP is a kind of HTML embedded language. PHP is somewhat similar to Microsoft's ASP. It is a scripting language that embeds HTML documents on the server. The style of the language is similar to C language, and now it is widely used by many website programmers.
After reading the above, do you have any further understanding of how to deploy the php project remotely? If you want to know more knowledge or related content, please follow the industry information channel, thank you for your support.
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.