玩龙天子 发表于 2018-10-7 10:18:47

Mantisbt 2.8+nginx+php+mysql+安装记录

  想弄个bug系统,找了好多款,发现没几个比较合适自身水平的
  搭建的简易版本的、仅供参考
  一、搭建环境
  Centos7.2
  Mantisbt2.8
  Nginx阿里云版本
  Mariadb阿里云版本
  PHP5.6(阿里云yum源只有5.4版本)
  阿里的yum
  参考网页:
  基础 http://rexchow.blog.51cto.com/11619161/1885533
  PHP 更新:http://blog.csdn.net/zhaozuosui/article/details/48394409
  Mantisbt 设置问题
  1、邮箱设置:http://www.cnblogs.com/jinxiudaxin/articles/5233840.html
  2、权限设置:
  
  二、搭建LNMP
  
  1、Web
  
yum group install Development Tools  #安装开发工具,GCC...
yum install mariadb mariadb-server php php-mysql php-gd libjpeg* php-imap php-ldap php-odbc php-pear php-xml php-xmlrpc php-mbstring php-mcrypt php-bcmath php-mhash libmcrypt -y  #安装apache mariadb php以及各种运行库和工具
setenforce 0  #关闭selinux
systemctl stop firewalld  #关闭防火墙嘛
  #安装nginx
yum install nginx -y  提供测试页(由于原来直接装的apache,所以这里就不提供测试了)大家仔细设置好nginx的root路径,可以测试php
12345# vim /var/www/html/index.php# cat /var/www/html/index.php  #安装后修改配置文件
  cd /etc/nginx
  mv nginx.conf.default nginx.conf
  #我使用的目录是/var/mantis/mantisbt-2.8.0/
  #要注意下面两个路径
fastcgi_param  
root   /var/mantis/mantisbt-2.8.0;
  #大家可以根据自己的目录所决定
  #nginx.conf配置内容
# cat nginx.conf  

  
#userroot;
  
worker_processes1;
  

  
events {
  
    worker_connections1024;
  
}
  

  

  
http {
  
    include       mime.types;
  
    default_typeapplication/octet-stream;
  

  
    sendfile      on;
  

  
    keepalive_timeout65;
  

  

  
    server {
  
      listen       80;
  
      server_namewww.rex.com;
  

  
      location / {
  
            root   /var/mantis/mantisbt-2.8.0;
  
            indexindex.php index.html index.htm;
  
      }
  

  
      error_page   500 502 503 504/50x.html;
  
      location = /50x.html {
  
            root   html;
  
      }
  
      location ~ \.php$ {
  
            root         html;
  
            fastcgi_pass   127.0.0.1:9000;
  
            fastcgi_indexindex.php;
  
            fastcgi_paramSCRIPT_FILENAME /var/mantis/mantisbt-2.8.0$fastcgi_script_name;
  
            include      fastcgi_params;
  
      }
  

  
    }
  

  

  
}
  给mantis添加权限
chmod -R 775 /var/mantis  2、Mariadb
  网上许多教程都是使用mysql
  由于版本的问题,还是使用有开源协议的mariadb,使用方法与mysql一样
  上面的yum已经一次性安装了
  cp /usr/share/mysql/my-huge.cnf /etc/my.cnf #拷贝配置文件(注意:如果/etc目录下面默认有一个my.cnf,直接覆盖即可)
  接下来进行MariaDB的相关简单配置
mysql_secure_installation  首先是设置密码,会提示先输入密码
  Enter current password for root (enter for none):
页: [1]
查看完整版本: Mantisbt 2.8+nginx+php+mysql+安装记录