参考:https://zhiyicx.github.io/ts-api-docs/guide/installation/using-nginx-and-fpm-publish-website.html#php-fpm-%E5%90%AF%E5%8A%A8

本次部署为阿里云上部署测试环境:

环境要求:阿里云ECS一台配置可以为最低1C1G,RDS一个,最低配置。SLB一个。

部署方式:nginx\php\plus 全编译,中间去除jeknins配置。

系统:Centos8.5.211

php 7.4.28 源码。

防火墙 selinux全部关闭。rds可以连通。

1. 登录系统,

ssh *****

2. 配置YUM源

wget -O /etc/yum.repos.d/CentOS-Base.repo https://mirrors.aliyun.com/repo/Centos-vault-8.5.2111.repo

rpm -Uvh http://rpms.remirepo.net/enterprise/remi-release-8.rpm

dnf -y install dnf-utils

yum install epel*

yum clean all

yum makecache

yum update

安装第三方源

wget http://www.atomicorp.com/installers/atomic

chmod 777 atomic

./atomic

3. 安装依赖包

yum install -y gcc autoconf gcc-c++ libxml2 libxml2-devel openssl openssl-devel bzip2 bzip2-devel libcurl libcurl-devel libjpeg libjpeg-devel libpng libpng

-devel freetype freetype-devel gmp gmp-devel readline readline-devel libxslt libxslt-devel libmcrypt libmcrypt-devel mhash mhash-devel systemd-devel openjpeg-devel

注意一些包没有安装上,记录没有安装上的包

wget https://download-ib01.fedoraproject.org/pub/epel/8/Everything/x86_64/Packages/l/libmcrypt-devel-2.5.8-26.el8.x86_64.rpm

wget https://download-ib01.fedoraproject.org/pub/epel/8/Everything/SRPMS/Packages/l/libmcrypt-2.5.8-26.el8.src.rpm

wget https://download-ib01.fedoraproject.org/pub/epel/8/Everything/x86_64/Packages/m/mhash-0.9.9.9-20.el8.x86_64.rpm

wget https://download-ib01.fedoraproject.org/pub/epel/8/Everything/x86_64/Packages/m/mhash-devel-0.9.9.9-20.el8.x86_64.rpm

yum install *.rpm

yum install openjpeg*

yum install libmcrypt libmcrypt-devel mhash mhash-devel openjpeg-devel

4. 编译PHP

groupadd php-fpm && useradd -s /sbin/nologin -g php-fpm -M php-fpm

yum -y install systemd-devel

yum -y install libxml*

yum install krb5*

yum install openssl*

yum install sqlite*

yum install bzip*

yum install libcurl-d*

yum config-manager --set-enabled PowerTools

yum -y install oniguruma oniguruma-devel

yum install libxslt*

yum install libzip-devel

yum install libpng-*

yum install freetype*

yum install libjpeg*

./configure --prefix=/usr/local/php --with-config-file-path=/usr/local/php/etc --with-zlib-dir --with-freetype=/usr/include/freetype2/ --enable-mbstring --

with-libxml --enable-xmlreader --enable-xmlwriter --enable-soap --enable-calendar --with-curl --with-zlib --enable-gd --with-pear --with-pdo-sqlite --with-pdo-mys

ql --with-mysqli --with-mysql-sock --enable-mysqlnd --disable-rpath --enable-inline-optimization --with-bz2 --with-zlib --enable-sockets --enable-sysvsem --enable

-sysvshm --enable-pcntl --enable-mbregex --enable-exif --enable-bcmath --with-mhash --with-zip --with-pcre-jit --with-external-pcre --with-jpeg --with-openssl --e

nable-ftp --with-kerberos --with-gettext --with-xmlrpc --with-xsl --enable-fpm --with-fpm-user=php-fpm --with-fpm-group=php-fpm --with-fpm-systemd

make && make install

其它按参考文档走

5. 配置RDS

6. 安装plus

plus项目代码下载后,需要手工创建目录

cd storage/

mkdir framework

cd framework/

mkdir sessions

mkdir testing

mkdir views

composer update -vvv

yum install redis -y

service redis restart

6.nginx+php-fpm方式发布。

其它按文档:

注意:对外网址为https协议的时候,需要在app 的http参数 配置为true,默认是关闭的。否则浏览器会提示不安全,无法打开。

新开通了微信公众号方便的朋友关注一下:

搜“蓝鲸技术简要”

最新文章

  1. SQL常见优化Sql查询性能的方法有哪些?
  2. 【软件工程实践一】git使用心得
  3. Shell 语法之输入输出
  4. 【BZOJ1812】riv(多叉树转二叉树,树形DP)
  5. Configuring HugePages for Oracle on Linux (x86-64)
  6. 内存映射 madvise mmap
  7. delphi TSaveDialog
  8. ubuntu 步步为营之uclinux编译和移植(完整版)
  9. C++的精髓——虚函数
  10. 关于Java中String类的hashCode方法
  11. ssm打印sql语句
  12. R语言-离职率分析
  13. eclipse自定义工作区列表
  14. Lucene.Net如何实现搜索结果分类统计功能
  15. mui 普通新闻文字列表 图文新闻列表
  16. 第一章 C#入门 (Windows窗体应用程序)(三)
  17. 2017-2018-2 20155303『网络对抗技术』Exp4:恶意代码分析
  18. markdown简单入门
  19. flask + mysql写的简单监控系统
  20. oAuth2.0在laravel5.2中的简单应用

热门文章

  1. Windows必装软件,一个比一个好用
  2. 昇腾AI新技能,还能预防猪生病?
  3. Python ( 高级 第一部)
  4. ARC157E XXYX Binary Tree 题解
  5. drf内容总结
  6. 金蝶AAS-V9精简版使用手册1.6
  7. vue移动端禁止弹层穿透、点击元素滚动到视图中心杂文日志
  8. vue node Failed at the iview-admin
  9. vite+vue3.0+ts搭建项目
  10. 浅谈hive