centos7中怎么搭建ShowDoc
这期内容当中小编将会给大家带来有关centos7中怎么搭建ShowDoc,文章内容丰富且以专业的角度为大家分析和叙述,阅读完这篇文章希望大家可以有所收获。
在普洱等地区,都构建了全面的区域性战略布局,加强发展的系统性、市场前瞻性、产品创新能力,以专注、极致的服务理念,为客户提供网站制作、成都网站建设 网站设计制作按需网站开发,公司网站建设,企业网站建设,品牌网站建设,全网营销推广,外贸网站制作,普洱网站建设费用合理。
1、nginx
yum install -y epel-release
yum install -y nginx
cp /etc/nginx/nginx.conf /etc/nginx/nginx.conf.bak
#修改nginx配置文件
vim /etc/nginx/nginx.conf
38 server {
39 listen 80 default_server;
40 listen [::]:80 default_server;
41 server_name _;
42 root /var/www/html;
43 index index.php index.html;
44
45 # Load configuration files for the default server block.
46 include /etc/nginx/default.d/*.conf;
47
48 location / {
49 }
50
51 error_page 404 /404.html;
52 location = /40x.html {
53 }
54
55 error_page 500 502 503 504 /50x.html;
56 location = /50x.html {
57 }
58 location ~ .php$ {
59 root /var/www/html;
60 fastcgi_pass 127.0.0.1:9000;
61 fastcgi_index index.php;
62 fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
63 include fastcgi_params;
64 }
65 location ~ /.ht {
66 deny all;
67 }
68 }
systemctl start nginx
systemctl enable nginx
2、PHP
yum install -y php php-gd php-fpm php-mcrypt php-mbstring php-MySQL php-pdo
systemctl start php-fpm
systemctl enable php-fpm
#下载安装PHP的依赖管理工具,Composer
curl -sS https://getcomposer.org/installer | php
cp composer.phar /usr/local/bin/composer
composer config -g repo.packagist composer https://packagist.phpcomposer.com
cd /var/www/html
composer create-project showdoc/showdoc
chmod a+w showdoc/install
chmod a+w showdoc/Sqlite
chmod a+w showdoc/Sqlite/showdoc.db.php
chmod a+w showdoc/Public/Uploads/
chmod a+w showdoc/Application/Runtime/
chmod a+w showdoc/server/Application/Runtime
chmod a+w showdoc/Application/Common/Conf/config.php
chmod a+w showdoc/Application/Home/Conf/config.php
3、访问
http://host-ip/showdoc/install
4、禁止注册
cp /var/www/html/showdoc/server/Application/Api/Controller/UserController.class.php{,.bak}
vim /var/www/html/showdoc/server/Application/Api/Controller/UserController.class.php
7 //注册
8 public function register(){
9 $this->sendError(10101,'no register');
10 return;
上述就是小编为大家分享的centos7中怎么搭建ShowDoc了,如果刚好有类似的疑惑,不妨参照上述分析进行理解。如果想知道更多相关知识,欢迎关注创新互联行业资讯频道。
新闻名称:centos7中怎么搭建ShowDoc
分享URL:http://ybzwz.com/article/iiogjc.html