• Home
  • Archive
  • Tools
  • Contact Us

The Customize Windows

Technology Journal

  • Cloud Computing
  • Computer
  • Digital Photography
  • Windows 7
  • Archive
  • Cloud Computing
  • Virtualization
  • Computer and Internet
  • Digital Photography
  • Android
  • Sysadmin
  • Electronics
  • Big Data
  • Virtualization
  • Downloads
  • Web Development
  • Apple
  • Android
Advertisement
You are here: Home » Install Phabricator on Ubuntu 14.04, Nginx (Cloud Server)

By Abhishek Ghosh December 30, 2015 10:50 am Updated on December 30, 2015

Install Phabricator on Ubuntu 14.04, Nginx (Cloud Server)

Advertisement

Phabricator is multipurpose software. We are describing for using with bigger WordPress website for extra team works. For our business related works our S/W Engineers use Phabricator. In fact, the reason we typically use forums for blogs (receiving bugs, errata, suggestion etceteras for any post) can be done with Phabricator. Here is How to Install Phabricator on Ubuntu 14.04, Nginx Running on a Typical Cloud Server Instance. Development is related to Facebook, Facebook is related to PRISM. Hence, possibly you need to do a bit research about security for projects which demands huge security.

Some documentation are here :

Vim
1
https://secure.phabricator.com/book/phabricator/article/configuration_guide/

After following this guide, you’ll do the later steps reading from there. For Apache, there is ready to use script :

Advertisement

---

Vim
1
https://secure.phabricator.com/diffusion/P/browse/master/scripts/install/install_ubuntu.sh

 

Install Phabricator on Ubuntu 14.04, Nginx : Requirements

 

Phabricator is designed to get installed on the root of a Fully Qualified Domain Name – either subdomain or domain. thecustomizewindows.com or subdomain like report.thecustomizewindows.com. That may be a problem with HSTS setup, if WordPress is already running on the same server. In other words, use VPSDime like $7/month great 6GB server (Use without fear. No downtime, better than Rackspace.) and use a third party DNS service provider like CloudFlare or paid like Dyn, install SSL certificate for Nginx in normal way. Yes, the full work will take time.

We will assume that nothing is installed on the server. We will not discuss about SSL/TLS certificate installation. Use the search function on our website to get help for problems with steps.

 

Install Phabricator on Ubuntu 14.04, Nginx : Steps

 

Following the full guide to install, optimize LEMP for WordPress actually will work fine. However, we have to “officially” write the steps!

Installing PHP and Other Stuffs

Vim
1
apt-get install -y subversion git-core git php5-fpm php5-mysql php5-curl php5-mysql php5-gd php5-cli php5-dev php5-json

Edit the file :

/etc/php5/cli/php.ini
Vim
1
2
3
4
5
6
7
8
nano /etc/php5/cli/php.ini
# use ^ + W
# to find date.timezone
# and add
date.timezone = Calcutta/Asia
# see php timezones - http://php.net/manual/en/timezones.asia.php
# use ^ + W to find apc.stat, add
apc.stat = Off

repeat it for /etc/php5/fpm/php.ini, then do configtest with php5-fpm -t and reload with service php5-fpm restart command(s).

Installing Nginx as Webserver

We are installing Nginx Extras from repo :

Vim
1
2
3
4
5
6
sudo useradd -g www-data nginx
usermod -a -G www-data nginx
# reboot, exit ssh session and login
sudo apt–get install nginx-extras
# create this dir
mkdir -p /var/repo

We think, you know how to configure Nginx for PHP, in case you never used Nginx, configure with our previous guide.

Install Phabricator on Ubuntu 14.04, Nginx Cloud Server

Our normal root is /usr/share/nginx/html for Nginx’s public FTP and vhost file is /etc/nginx/sites-available/default. We do not change these as for guides. It is a moronic work to change them. If we cd to /usr/share/nginx/html to work, that will append phabricator/webroot as web root. If you cd to /usr/share/ and create phabricator directory, /usr/share/phabricator/phabricator/webroot as root. It is more moronic to see phabricator twice in path. Instead we can chown, chgrp to proper settings to secure the installation. So :

We will work by going to : /usr/share/nginx/html
Nginx – Phabricator will set FTP root to : /usr/share/nginx/html/phabricator/webroot
We will run various scripts from : /usr/share/nginx/html/phabricator/

We can install Phabricator from :

Vim
1
https://github.com/phacility/phabricator

But we will install from github.com/facebook/phabricator, so starting from :

Vim
1
2
3
4
cd /usr/share/nginx/html/
git clone git://github.com/facebook/libphutil.git
git clone git://github.com/facebook/arcanist.git
git clone git://github.com/facebook/phabricator.git

We need to chgrp the /usr/share/nginx/html/phabricator/webroot to root:www-data :

Vim
1
sudo chown www-data:nginx /usr/share/nginx/html/phabricator/webroot -R

As we will install on /usr/share/nginx/html/phabricator/webroot, so that typical configuration needs modification for non-SSL as example (you should configtest with nginx -t command, it is not tested) :

Vim
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
server {
  server_name report.thecustomizewindows.com;
  root      /usr/share/nginx/html/phabricator/webroot;
  try_files $uri $uri/ /index.php;
  location / {
    index   index.php;
    if ( !-f $request_filename )
    {
      rewrite ^/(.*)$ /index.php?__path__=/$1 last;
      break;
    }
  }
location /index.php {
    fastcgi_pass   127.0.0.1:9000;
    fastcgi_index   index.php;
    fastcgi_param  REDIRECT_STATUS    200;
    fastcgi_param  SCRIPT_FILENAME    $document_root$fastcgi_script_name;
    fastcgi_param  QUERY_STRING       $query_string;
    fastcgi_param  REQUEST_METHOD     $request_method;
    fastcgi_param  CONTENT_TYPE       $content_type;
    fastcgi_param  CONTENT_LENGTH     $content_length;
    fastcgi_param  SCRIPT_NAME        $fastcgi_script_name;
    fastcgi_param  GATEWAY_INTERFACE  CGI/1.1;
    fastcgi_param  SERVER_SOFTWARE    nginx/$nginx_version;
    fastcgi_param  REMOTE_ADDR        $remote_addr;
  }
}

For SSL as example :

Vim
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
server {
listen 80;
  server_name report.thecustomizewindows.com;
  root      /usr/share/nginx/html;
   location / {
        rewrite ^ https://$http_host$request_uri? permanent;
    }
}
server {
listen 443 ssl;
  server_name report.thecustomizewindows.com;
  root      /usr/share/nginx/html/phabricator/webroot;
  try_files $uri $uri/ /index.php;
  ssl on;
# certs at /etc/nginx/ssl/report/
  ssl_certificate /etc/nginx/ssl/report/thecustomizewindows.com.crt;
  ssl_certificate_key /etc/nginx/ssl/report/thecustomizewindows.com.key;
  ssl_session_timeout 30m;
  location / {
    index   index.php;
    if ( !-f $request_filename )
    {
      rewrite ^/(.*)$ /index.php?__path__=/$1 last;
      break;
    }
location /index.php {
    fastcgi_pass   127.0.0.1:9000;
    fastcgi_index   index.php;
    fastcgi_param  REDIRECT_STATUS    200;
    fastcgi_param  SCRIPT_FILENAME    $document_root$fastcgi_script_name;
    fastcgi_param  QUERY_STRING       $query_string;
    fastcgi_param  REQUEST_METHOD     $request_method;
    fastcgi_param  CONTENT_TYPE       $content_type;
    fastcgi_param  CONTENT_LENGTH     $content_length;
    fastcgi_param  SCRIPT_NAME        $fastcgi_script_name;
    fastcgi_param  GATEWAY_INTERFACE  CGI/1.1;
    fastcgi_param  SERVER_SOFTWARE    nginx/$nginx_version;
    fastcgi_param  REMOTE_ADDR        $remote_addr;
  }
}

Check the /etc/php5/fpm/pool.d/www.conf for listen = 127.0.0.1:9000, we are not using UNIX socket, else you’ll get odd 502 error like if we use UNIX socket on www.conf but port 9000 on default Nginx configuration file. Keep in mind – normally we use UNIX socket in our all guides, we are using port here, i.e. 127.0.0.1:9000 as not huge number of users reported any problems with UNIX socket and port, unlike WordPress. Port is fail safe.

Installing MySQL for Phabricator on Ubuntu 14.04

We are installing Percona MySQL :

Vim
1
2
3
4
5
6
7
8
9
apt update –y && apt upgrade
apt dist–upgrade
apt–key adv —keyserver keys.gnupg.net —recv–keys 1C4CBDCDCD2EFD2A
echo “deb http://repo.percona.com/apt lsb_release -cs main” >> /etc/apt/sources.list.d/percona.list
echo “deb-src http://repo.percona.com/apt lsb_release -cs main” >> /etc/apt/sources.list.d/percona.list
apt–get update
sudo apt–get install percona–server–server–5.6 percona–server–client–5.6
sudo mysql_install_db
sudo mysql_secure_installation

Create a database :

Vim
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
mysql –u root –h localhost –p
# run after login
CREATE FUNCTION fnv1a_64 RETURNS INTEGER SONAME 'libfnv1a_udf.so';
CREATE FUNCTION fnv_64 RETURNS INTEGER SONAME 'libfnv_udf.so';
CREATE FUNCTION murmur_hash RETURNS INTEGER SONAME 'libmurmur_udf.so';
# you should exit
exit
# then restart mysql
service mysql restart
# mysql –u root –h localhost –p
# In case you need non-root user and own database
CREATE USER 'yourserver2016'@'localhost' IDENTIFIED BY 'BADPASSWORD__a&ET#';
CREATE DATABASE phabricator2016;
GRANT SELECT,DELETE,INSERT,UPDATE ON phabricator2016.* TO 'yourserver2016'@'localhost';
GRANT ALL PRIVILEGES ON phabricator2016.* TO 'yourserver2016'@'localhost';
FLUSH PRIVILEGES;

Most important to read how to “enable” Auto Restart of MySQL. In /etc/mysql/my.cnf add the following lines under the [mysqld] section :

/etc/mysql/my.cnf
Vim
1
2
sql_mode = STRICT_ALL_TABLES
ft_min_word_len = 3

Restart with service mysql restart command. Actually, Phabricator has script to create database, you can run in this way, change password to your password, user to the created user in above steps.

Vim
1
2
3
4
5
6
cd /usr/share/nginx/html/phabricator/
./bin/config set mysql.host 127.0.0.1
./bin/config set mysql.port 3306
./bin/config set mysql.user yourserver2016
./bin/config set mysql.pass BADPASSWORD__a&ET#
./bin/storage upgrade --user yourserver2016 --password BADPASSWORD__a&ET#

These commands set the base URI and forces all the daemons to start :

Vim
1
2
3
4
5
cd /usr/share/nginx/html/phabricator/
./bin/config set phabricator.base-uri 'https://report.thecustomizewindows.com/'
./bin/phd start
# use only if you are getting error in the next step
./bin/accountadmin

Now, visit that subdomain on Browser and start installation like WordPress.

Enabling Notification and Auto Restart on Reboot

We need Node.js :

Vim
1
2
3
sudo apt-get install nodejs
/usr/share/nginx/html/phabricator/bin/config set notification.enabled true
/usr/share/nginx/html/phabricator/bin/aphlict start

Edit /etc/rc.local to automate start on reboot, add :

Vim
1
2
/usr/share/nginx/html/phabricator/bin/phd start
/usr/share/nginx/html/phabricator/bin/aphlict start

Thats it.

Tagged With erver_name phabricator example com; root /path/to/phabricator/webroot; location / { index index php; rewrite ^/( *)$ /index php?__path__=/$1 last; } location /index php { fastcgi_pass localhost:9000; fastcgi_index index php; #required if PHP was built wit , https://thecustomizewindows com/2015/12/install-phabricator-on-ubuntu-14-04-nginx-cloud-server/ , https://yandex ru/clck/jsredir?from=yandex ru;search;web;;&text=&etext=1840 9uvqmdl1Tw4YATnLcsUHO6_7uO80kJsRPFgRXRjUXNpvm8Flp-wfWynQZzf8cSvv 4911f672c7f5f8db580962971412036ad534bddd&uuid=&state=_BLhILn4SxNIvvL0W45KSic66uCIg23qh8iRG98qeIXme , install phabricator , installing phabricator on ubuntu , ubuntu apt phabricator , ubuntu phabricator

This Article Has Been Shared 886 Times!

Facebook Twitter Pinterest

Abhishek Ghosh

About Abhishek Ghosh

Abhishek Ghosh is a Businessman, Surgeon, Author and Blogger. You can keep touch with him on Twitter - @AbhishekCTRL.

Here’s what we’ve got for you which might like :

Articles Related to Install Phabricator on Ubuntu 14.04, Nginx (Cloud Server)

  • Application Service Provider (ASP) and Cloud Computing

    Application Service Provider or ASP is a service of an application for exchanging information over a public network and is used over PaaS now as SaaS.

  • Cloud Computing Agility : The Converged Technologies

    Cloud Computing Agility is a characteristic feature of Cloud which allows to gain the speed in development and deployment of applications and Services.

  • Criteria for ERP SaaS Applications

    Criteria for ERP SaaS Applications should fit regardless of the chosen deployment model like on-premise, SaaS or hybrid, an ERP system should be functional.

  • Data on Cloud and Legal Fog Around

    Data on Cloud has some unclear spots like in case when the provider operate not under same nations law, but law of a foreign jurisdiction, that can add issues.

  • Cloud Computing for SMBs : Path to the Cloud

    In any case, the turn to cloud for medium to small business means a change in the operating models. But what are the necessary steps to achieve that?

Additionally, performing a search on this website can help you. Also, we have YouTube Videos.

Take The Conversation Further ...

We'd love to know your thoughts on this article.
Meet the Author over on Twitter to join the conversation right now!

If you want to Advertise on our Article or want a Sponsored Article, you are invited to Contact us.

Contact Us

Subscribe To Our Free Newsletter

Get new posts by email:

Please Confirm the Subscription When Approval Email Will Arrive in Your Email Inbox as Second Step.

Search this website…

 

Popular Articles

Our Homepage is best place to find popular articles!

Here Are Some Good to Read Articles :

  • Cloud Computing Service Models
  • What is Cloud Computing?
  • Cloud Computing and Social Networks in Mobile Space
  • ARM Processor Architecture
  • What Camera Mode to Choose
  • Indispensable MySQL queries for custom fields in WordPress
  • Windows 7 Speech Recognition Scripting Related Tutorials

Social Networks

  • Pinterest (24.3K Followers)
  • Twitter (5.8k Followers)
  • Facebook (5.7k Followers)
  • LinkedIn (3.7k Followers)
  • YouTube (1.3k Followers)
  • GitHub (Repository)
  • GitHub (Gists)
Looking to publish sponsored article on our website?

Contact us

Recent Posts

  • What is an Automatic Ethanol Fireplace February 8, 2023
  • Disadvantages of Cloud-Native Computing February 7, 2023
  • Projector Screen Basics February 6, 2023
  • What is Configuration Management February 5, 2023
  • What is ChatGPT? February 3, 2023

About This Article

Cite this article as: Abhishek Ghosh, "Install Phabricator on Ubuntu 14.04, Nginx (Cloud Server)," in The Customize Windows, December 30, 2015, February 8, 2023, https://thecustomizewindows.com/2015/12/install-phabricator-on-ubuntu-14-04-nginx-cloud-server/.

Source:The Customize Windows, JiMA.in

PC users can consult Corrine Chorney for Security.

Want to know more about us? Read Notability and Mentions & Our Setup.

Copyright © 2023 - The Customize Windows | dESIGNed by The Customize Windows

Copyright  · Privacy Policy  · Advertising Policy  · Terms of Service  · Refund Policy

We use cookies on our website to give you the most relevant experience by remembering your preferences and repeat visits. By clicking “Accept”, you consent to the use of ALL the cookies.
Do not sell my personal information.
Cookie SettingsAccept
Manage consent

Privacy Overview

This website uses cookies to improve your experience while you navigate through the website. Out of these, the cookies that are categorized as necessary are stored on your browser as they are essential for the working of basic functionalities of the website. We also use third-party cookies that help us analyze and understand how you use this website. These cookies will be stored in your browser only with your consent. You also have the option to opt-out of these cookies. But opting out of some of these cookies may affect your browsing experience.
Necessary
Always Enabled
Necessary cookies are absolutely essential for the website to function properly. These cookies ensure basic functionalities and security features of the website, anonymously.
CookieDurationDescription
cookielawinfo-checkbox-analytics11 monthsThis cookie is set by GDPR Cookie Consent plugin. The cookie is used to store the user consent for the cookies in the category "Analytics".
cookielawinfo-checkbox-functional11 monthsThe cookie is set by GDPR cookie consent to record the user consent for the cookies in the category "Functional".
cookielawinfo-checkbox-necessary11 monthsThis cookie is set by GDPR Cookie Consent plugin. The cookies is used to store the user consent for the cookies in the category "Necessary".
cookielawinfo-checkbox-others11 monthsThis cookie is set by GDPR Cookie Consent plugin. The cookie is used to store the user consent for the cookies in the category "Other.
cookielawinfo-checkbox-performance11 monthsThis cookie is set by GDPR Cookie Consent plugin. The cookie is used to store the user consent for the cookies in the category "Performance".
viewed_cookie_policy11 monthsThe cookie is set by the GDPR Cookie Consent plugin and is used to store whether or not user has consented to the use of cookies. It does not store any personal data.
Functional
Functional cookies help to perform certain functionalities like sharing the content of the website on social media platforms, collect feedbacks, and other third-party features.
Performance
Performance cookies are used to understand and analyze the key performance indexes of the website which helps in delivering a better user experience for the visitors.
Analytics
Analytical cookies are used to understand how visitors interact with the website. These cookies help provide information on metrics the number of visitors, bounce rate, traffic source, etc.
Advertisement
Advertisement cookies are used to provide visitors with relevant ads and marketing campaigns. These cookies track visitors across websites and collect information to provide customized ads.
Others
Other uncategorized cookies are those that are being analyzed and have not been classified into a category as yet.
SAVE & ACCEPT