phabricator安裝記錄

安裝方式使用的是官網的安裝腳本,官網的安裝教程:
https://secure.phabricator.com/book/phabricator/article/installation_guide/

主要安裝過程說明:

1、從官網下載安裝腳本(將會安裝apache、php等環境,不會安裝mysql)

下載地址:
https://p.phcdn.net/file/download/@secure/67k3d4si5lyffxaxba6q/PHID-FILE-mq4el6evrr57bspsublr/install_rhel-derivs.sh

2、執行腳本

1)將腳本上傳到將要安裝的服務器的相關目錄,如/usr/local/phabricator
2)添加執行權限

chmod +x install_rhel-derivs.sh

3)執行安裝腳本

cd /usr/local/phabricator
./install_rhel-derivs.sh
3、配置Apache,官網配置說明:

https://secure.phabricator.com/book/phabricator/article/configuration_guide/
1)把配置文件中的下面一段配置註釋掉,因爲默認配置/目錄是禁止所有訪問

#<Directory />
#    AllowOverride none
#    Require all denied
#</Directory>

2)添加如下配置到文件中

<VirtualHost *>
  # Change this to the domain which points to your host.
  ServerName cr.gsafety.com

  # Change this to the path where you put 'phabricator' when you checked it
  # out from GitHub when following the Installation Guide.
  #
  # Make sure you include "/webroot" at the end!
  DocumentRoot /usr/local/phabricator/phabricator/webroot

  RewriteEngine on
  RewriteRule ^(.*)$          /index.php?__path__=$1  [B,L,QSA]
</VirtualHost>

<Directory "/usr/local/phabricator/phabricator/webroot">
  Order allow,deny
  Allow from all
</Directory>

3)打開ServerName,默認是註釋掉的。
4) 啓動Apache

/usr/sbin/httpd -k start
或
/usr/sbin/httpd -k restart
4、修改/etc/hosts(如果沒有域名的話)
5、安裝MySQL(略)
6、使用./bin/config配置數據庫
cd /usr/local/phabricator/phabricator/
./bin/config set mysql.host 192.168.46.1
./bin/config set mysql.user root
./bin/config set mysql.pass 123456
7、升級php版本到5.5以上
yum list installed|grep php
yum remove php
yum remove php-*

rpm -Uvh http://rpms.famillecollet.com/enterprise/remi-release-7.rpm
yum -y install php71-php php71-php-common php71-php-devel php71-php-gd php71-php-mysqlnd php71-php-pecl-mysql php71-php-pecl-memcached php71-php-pecl-memcache php71-php-pecl-redis php71-php-opcache php71-php-mbstring php71-php-posix php71-php-apcu php71-php-zip
php -v
8、執行./bin/storage upgrade,完成
9、附錄:

主要操作命令記錄:

cd /usr/local/
mkdir phabricator
cd phabricator/
./install_rhel-derivs.sh 
vim /etc/httpd/conf/httpd.conf 
vi /etc/hosts
ping cr.gsafety.com
/usr/sbin/httpd -k restart
firewall-cmd --state
systemctl stop firewalld
cd /usr/local/phabricator/
cd phabricator/
./bin/storage upgrade
which php
php -v
yum list installed|grep php
yum remove php
yum remove php-*
rpm -Uvh http://rpms.famillecollet.com/enterprise/remi-release-7.rpm
yum -y install php72-php php72-php-common php72-php-devel php72-php-gd php72-php-mysqlnd php72-php-pecl-mysql php72-php-pecl-memcached php72-php-pecl-memcache php72-php-pecl-redis php72-php-opcache
php -v
which php
find / -name php
/opt/remi/php72/root/usr/bin/php -v
vi .bash_profile 
source .bash_profile 
php -v
cd /usr/local/phabricator/phabricator/
./bin/config set mysql.host 192.168.46.1
./bin/config set mysql.user root
./bin/config set mysql.pass 123456
./bin/storage upgrade

參考資料:
[1] https://www.cnblogs.com/ruanqin/p/10837971.html,yum升級php版本

發表評論
所有評論
還沒有人評論,想成為第一個評論的人麼? 請在上方評論欄輸入並且點擊發布.
相關文章