当前位置:网站首页>Record the migration process of a project
Record the migration process of a project
2022-07-07 16:25:00 【Bashan queer dialect】
The number of servers applying for Alibaba cloud student accounts has risen to 500 More , Resolutely change to the cool server of Tencent cloud , It's only a year 39, The configuration is much higher than that of Alibaba cloud
No containerization Technology , It's pure manual handling , recorded , If nothing else , We have to change cloud service providers next year
The pagoda panel is used for project deployment and database configuration , Simple to use , Time saving and labor saving , I hate doing some work at the bottom of the stage , Understand
1、 Back up projects and databases
SSH For client tools XSehll
FTP Tools XFtp
Use FTP Download all the deployed projects to the local . Whether it's node project 、vue The project is still django project , Delete dependencies first , Download again , It can save a lot of download time
Use PhpAdmin Export the database to local
2、 Domain name resolution
Re resolve all primary and secondary domain names to the new Tencent ECS address , This is very fast
3、 Tencent cloud server environment configuration
3.1 nginx To configure
Connect to the new Tencent cloud server , First install the pagoda panel , At the same time to install Nginx, In fact, it's better to put MySQL and PHP It's also installed .
Because the latest pagoda panel can help us quickly deploy PHP 、Java and Node project
For example, the front-end project belongs to a pure static project , You can also use "PHP" In the project “ Add site ” Function deployment
although PHP The version there , You can choose pure static , But when submitted , You're going to report a mistake , I can't find “enable-php.conf”
stay /www/server/nginx/conf Find below nginx.conf open , Found that there is such a line of code , But the current directory does not enable-php.conf The file of , therefore , Just one of them is installed php7.4, And then change to , restart nginx All right
include enable-php-74.conf;
analysis : I don't know if it's because I only installed nginx , No installation php It matters , But installed php7.4 , After modifying the configuration , That's fine . Today, I suddenly found one in the above Directory enable-php.conf file , So change the above configuration file to the default value , Sure enough, you can still successfully add the site
Have time to study this enable.php.conf file
3.2 Project upload deployment
This step is relatively simple
Put the front-end project 、node The project and django Upload the project to /www/wwwroot Under the table of contents , The installation that this installation depends on , The modified configuration of the modified configuration , Because I mapped the domain name , Not used IP Address , So the request of the front-end project API The address of the reference interface , There's no need to change .
The only thing that needs attention is django project
You can use the following tools to quickly deploy
After this tool is installed , Every time you need to “ Software store ” Of “ Installed project ” Find and use , Click on “ Set up ” New projects
You need to install python, Then you can select... In the above interface python edition .
python Use the pagoda panel to search and install
After the project is successfully deployed , Don't forget it. In profile , Configure allowed domain names and cross domains
I have set a cross domain setting here to allow all , Later, it will be changed to a specific domain name
in addition ,django Project online collection , For static files , For example, the access of pictures may appear 404
This is because after the project goes online , The configuration of static files in development mode will not work , It is recommended to use nginx Proxy for static files , The specific methods are as follows
open settings.py , Set debug mode to False
stay “ Website ” in , Item found , Click on " Set up "
Click on “ The configuration file ”, stay server Add the following code to
边栏推荐
- Laravel post shows an exception when submitting data
- You Yuxi, coming!
- Performance measure of classification model
- Eye of depth (VI) -- inverse of matrix (attachment: some ideas of logistic model)
- 统计学习方法——感知机
- Talk about the cloud deployment of local projects created by SAP IRPA studio
- Migration and reprint
- [vulnhub range] thales:1
- 无法将“pip”项识别为 cmdlet、函数、脚本文件或可运行程序的名称
- TCP framework___ Unity
猜你喜欢
Mysql database basic operation DQL basic query
Description of vs common shortcut keys
torch.numel作用
Application example of infinite list [uigridview]
Numpy -- epidemic data analysis case
融云斩获 2022 中国信创数字化办公门户卓越产品奖!
Odoo integrated plausible embedded code monitoring platform
[vulnhub range] thales:1
Xingruige database was shortlisted as the "typical solution for information technology application and innovation in Fujian Province in 2021"
AE learning 01: AE complete project summary
随机推荐
Leetcode-231-2的幂
Unity drawing plug-in = = [support the update of the original atlas]
torch. Numel action
应用程序和matlab的通信方式
What is the difference between IP address and physical address
prometheus api删除某个指定job的所有数据
Bidding announcement: 2022 Yunnan Unicom gbase database maintenance public comparison and selection project (second) comparison and selection announcement
深度之眼(七)——矩阵的初等变换(附:数模一些模型的解释)
Three. JS introductory learning notes 19: how to import FBX static model
修改配置文件后tidb无法启动
Performance measure of classification model
JS 模块化
谈谈 SAP iRPA Studio 创建的本地项目的云端部署问题
PHP中exit,exit(0),exit(1),exit(‘0’),exit(‘1’),die,return的区别
Shandong old age Expo, 2022 China smart elderly care exhibition, smart elderly care and aging technology exhibition
【Vulnhub靶场】THALES:1
星瑞格数据库入围“2021年度福建省信息技术应用创新典型解决方案”
Three singleton modes of unity (hungry man, lazy man, monobehavior)
laravel 是怎么做到运行 composer dump-autoload 不清空 classmap 映射关系的呢?
安科瑞电网智能化发展的必然趋势电力系统采用微机保护装置是