Skip to content

Instantly share code, notes, and snippets.

@andrwj
Forked from sparrc/phabricator_readme.md
Created November 16, 2022 10:51
Show Gist options
  • Save andrwj/d7c6424c2e7ecfa1c8e0ba266a23297e to your computer and use it in GitHub Desktop.
Save andrwj/d7c6424c2e7ecfa1c8e0ba266a23297e to your computer and use it in GitHub Desktop.

Revisions

  1. @sparrc sparrc revised this gist Oct 26, 2020. 1 changed file with 5 additions and 5 deletions.
    10 changes: 5 additions & 5 deletions phabricator_readme.md
    Original file line number Diff line number Diff line change
    @@ -23,7 +23,7 @@ And create repo directory if phabricator will be hosting repos:

    su phd
    cd /home/phd
    wget http://www.phabricator.com/rsrc/install/install_ubuntu.sh
    wget https://raw.githubusercontent.com/phacility/phabricator/master/scripts/install/install_ubuntu.sh
    bash install_ubuntu.sh

    #### Recommended Phabricator Configurations to set:
    @@ -41,7 +41,7 @@ cd /home/phd/phabricator

    # for local-disk file storage only:
    mkdir /home/phd/phabricator-files
    chmod -R 755 /home/phd/phabricator-files
    chmod -R 666 /home/phd/phabricator-files
    ./bin/config set storage.local-disk.path /home/phd/phabricator-files

    # Set true if you want to allow public http cloning:
    @@ -166,7 +166,7 @@ And also adjust max_allowed_packet to 32M (this line will already exist)

    Restart mysql and run phabricator storage upgrade:

    service restart mysql
    service mysql restart
    ./bin/storage upgrade

    #### Configure php:
    @@ -211,7 +211,7 @@ Create phabricator ssh daemon on port 22

    ```bash
    # Copy the examply sshd config
    cp /home/phd/phabricator/resources/sshd/sshd_config.phabricator.example /etc/ssh/sshd_config.phabricator
    cp /home/phd/phabricator/resources/sshd/sshd_config.phabricator.example /etc/ssh/sshd_config.phabricator.conf
    # Edit AuthorizedKeysCommand, AuthorizedKeysCommandUser, and AllowUsers
    vim /etc/ssh/sshd_config.phabricator
    # Start the phabricator sshd
    @@ -220,7 +220,7 @@ vim /etc/ssh/sshd_config.phabricator

    Now you should be able to run this command:

    echo {} | ssh [email protected] conduit conduit.ping
    echo [] | ssh [email protected] conduit conduit.ping

    And get output like this:

  2. Cam revised this gist Jun 26, 2015. 1 changed file with 1 addition and 1 deletion.
    2 changes: 1 addition & 1 deletion phabricator_readme.md
    Original file line number Diff line number Diff line change
    @@ -228,6 +228,6 @@ And get output like this:

    #### Refer to the phabricator configuration guide for next steps:

    At this point, you should be able to host and clone repositories via HTTP & SSH. Refer the the [Diffusion Hosting Configuration Guide](https://secure.phabricator.com/book/phabricator/article/diffusion_hosting/) for trouble-shooting.
    At this point, you should be able to host and clone repositories via HTTP & SSH. Refer to the [Diffusion Hosting Configuration Guide](https://secure.phabricator.com/book/phabricator/article/diffusion_hosting/) for trouble-shooting.

    Also see the official [Phabricator Configuration Guide](https://secure.phabricator.com/book/phabricator/article/configuration_guide/) for additional advanced configuration steps.
  3. Cam revised this gist Jun 25, 2015. 1 changed file with 1 addition and 1 deletion.
    2 changes: 1 addition & 1 deletion phabricator_readme.md
    Original file line number Diff line number Diff line change
    @@ -187,7 +187,7 @@ Then restart apache

    #### Enable ssh clone & push

    Change default ssh port to something other than port 22
    Change default ssh port to something other than port 22 (I like to use 2222)

    ```bash
    # edit Port setting here
  4. Cam revised this gist Jun 25, 2015. 1 changed file with 9 additions and 0 deletions.
    9 changes: 9 additions & 0 deletions phabricator_readme.md
    Original file line number Diff line number Diff line change
    @@ -187,6 +187,15 @@ Then restart apache

    #### Enable ssh clone & push

    Change default ssh port to something other than port 22

    ```bash
    # edit Port setting here
    vim /etc/ssh/sshd_config
    # restart sshd service
    service sshd restart
    ```

    Make executable ssh hook for phabricator ssh daemon

    ```bash
  5. Cam revised this gist Jun 25, 2015. 1 changed file with 2 additions and 2 deletions.
    4 changes: 2 additions & 2 deletions phabricator_readme.md
    Original file line number Diff line number Diff line change
    @@ -211,8 +211,8 @@ vim /etc/ssh/sshd_config.phabricator

    Now you should be able to run this command:

    echo {} | ssh vcs-user@phabricator.yourcompany.com conduit conduit.ping
    echo {} | ssh git@phabricator.mydomain.net conduit conduit.ping

    And get output like this:

    {"result":"orbital","error_code":null,"error_info":null}
  6. Cam revised this gist Jun 25, 2015. 1 changed file with 4 additions and 0 deletions.
    4 changes: 4 additions & 0 deletions phabricator_readme.md
    Original file line number Diff line number Diff line change
    @@ -187,6 +187,8 @@ Then restart apache

    #### Enable ssh clone & push

    Make executable ssh hook for phabricator ssh daemon

    ```bash
    # copy ssh hook to executable location
    cp /home/phd/phabricator/resources/sshd/phabricator-ssh-hook.sh /usr/lib/phabricator-ssh-hook.sh
    @@ -196,6 +198,8 @@ chmod 755 /usr/lib/phabricator-ssh-hook.sh
    vim /usr/lib/phabricator-ssh-hook.sh
    ```

    Create phabricator ssh daemon on port 22

    ```bash
    # Copy the examply sshd config
    cp /home/phd/phabricator/resources/sshd/sshd_config.phabricator.example /etc/ssh/sshd_config.phabricator
  7. Cam revised this gist Jun 25, 2015. 1 changed file with 9 additions and 1 deletion.
    10 changes: 9 additions & 1 deletion phabricator_readme.md
    Original file line number Diff line number Diff line change
    @@ -205,8 +205,16 @@ vim /etc/ssh/sshd_config.phabricator
    /usr/sbin/sshd -f /etc/ssh/sshd_config.phabricator
    ```

    Now you should be able to run this command:

    echo {} | ssh [email protected] conduit conduit.ping

    And get output like this:

    {"result":"orbital","error_code":null,"error_info":null}

    #### Refer to the phabricator configuration guide for next steps:

    At this point, you should be able to host and clone repositories via HTTP. Refer the the [Diffusion Hosting Configuration Guide](https://secure.phabricator.com/book/phabricator/article/diffusion_hosting/) to setup ssh repo access.
    At this point, you should be able to host and clone repositories via HTTP & SSH. Refer the the [Diffusion Hosting Configuration Guide](https://secure.phabricator.com/book/phabricator/article/diffusion_hosting/) for trouble-shooting.

    Also see the official [Phabricator Configuration Guide](https://secure.phabricator.com/book/phabricator/article/configuration_guide/) for additional advanced configuration steps.
  8. Cam revised this gist Jun 25, 2015. 1 changed file with 18 additions and 2 deletions.
    20 changes: 18 additions & 2 deletions phabricator_readme.md
    Original file line number Diff line number Diff line change
    @@ -185,9 +185,25 @@ Then restart apache

    ./bin/phd restart

    #### Get the phabricator update script:
    #### Enable ssh clone & push

    wget http://www.phabricator.com/rsrc/install/update_phabricator.sh
    ```bash
    # copy ssh hook to executable location
    cp /home/phd/phabricator/resources/sshd/phabricator-ssh-hook.sh /usr/lib/phabricator-ssh-hook.sh
    chown root /usr/lib/phabricator-ssh-hook.sh
    chmod 755 /usr/lib/phabricator-ssh-hook.sh
    # Modify hook to match your system (hint: vcs-user == git)
    vim /usr/lib/phabricator-ssh-hook.sh
    ```

    ```bash
    # Copy the examply sshd config
    cp /home/phd/phabricator/resources/sshd/sshd_config.phabricator.example /etc/ssh/sshd_config.phabricator
    # Edit AuthorizedKeysCommand, AuthorizedKeysCommandUser, and AllowUsers
    vim /etc/ssh/sshd_config.phabricator
    # Start the phabricator sshd
    /usr/sbin/sshd -f /etc/ssh/sshd_config.phabricator
    ```

    #### Refer to the phabricator configuration guide for next steps:

  9. Cam revised this gist Jun 25, 2015. 1 changed file with 5 additions and 3 deletions.
    8 changes: 5 additions & 3 deletions phabricator_readme.md
    Original file line number Diff line number Diff line change
    @@ -147,22 +147,24 @@ Make sure `mod_php` and `mod_rewrite` are enabled, and `mod_ssl` if you intend t
    # a2ensite phabricator
    # service apache2 restart

    #### Add these lines to /etc/mysql/my.cnf under the [mysqld] heading:
    #### Configure mysql and storage:

    Add these new lines to /etc/mysql/my.cnf under the [mysqld] heading:

    sql_mode=STRICT_ALL_TABLES
    ft_boolean_syntax=' |-><()~*:""&^'
    ft_stopword_file=/home/phd/phabricator/resources/sql/stopwords.txt
    ft_min_word_len=3

    This line should be about 40% of the memory of the box:
    This new line should be about 40% of the memory of the box:

    innodb_buffer_pool_size=800M

    And also adjust max_allowed_packet to 32M (this line will already exist)

    max_allowed_packet = 32M

    #### Restart mysql and run phabricator storage upgrade:
    Restart mysql and run phabricator storage upgrade:

    service restart mysql
    ./bin/storage upgrade
  10. Cam revised this gist Jun 25, 2015. 1 changed file with 1 addition and 1 deletion.
    2 changes: 1 addition & 1 deletion phabricator_readme.md
    Original file line number Diff line number Diff line change
    @@ -162,7 +162,7 @@ And also adjust max_allowed_packet to 32M (this line will already exist)

    max_allowed_packet = 32M

    #### Restart `mysql` and run phabricator storage upgrade:
    #### Restart mysql and run phabricator storage upgrade:

    service restart mysql
    ./bin/storage upgrade
  11. Cam revised this gist Jun 25, 2015. 1 changed file with 12 additions and 0 deletions.
    12 changes: 12 additions & 0 deletions phabricator_readme.md
    Original file line number Diff line number Diff line change
    @@ -167,6 +167,18 @@ And also adjust max_allowed_packet to 32M (this line will already exist)
    service restart mysql
    ./bin/storage upgrade

    #### Configure php:

    Adjust the following fields in `/etc/php5/apache2/php.ini`

    post_max_size = 8M
    date.timezone = Etc/UTC
    opcache.validate_timestamps=0

    Then restart apache

    service apache2 restart

    #### Restart phd daemons:

    ./bin/phd restart
  12. Cam revised this gist Jun 25, 2015. 1 changed file with 1 addition and 1 deletion.
    2 changes: 1 addition & 1 deletion phabricator_readme.md
    Original file line number Diff line number Diff line change
    @@ -164,7 +164,7 @@ And also adjust max_allowed_packet to 32M (this line will already exist)

    #### Restart `mysql` and run phabricator storage upgrade:

    # service restart mysql
    service restart mysql
    ./bin/storage upgrade

    #### Restart phd daemons:
  13. Cam revised this gist Jun 25, 2015. 1 changed file with 2 additions and 2 deletions.
    4 changes: 2 additions & 2 deletions phabricator_readme.md
    Original file line number Diff line number Diff line change
    @@ -154,11 +154,11 @@ Make sure `mod_php` and `mod_rewrite` are enabled, and `mod_ssl` if you intend t
    ft_stopword_file=/home/phd/phabricator/resources/sql/stopwords.txt
    ft_min_word_len=3

    This should be about 40% of the memory of the box:
    This line should be about 40% of the memory of the box:

    innodb_buffer_pool_size=800M

    And also adjust max_allowed_packet to 32M
    And also adjust max_allowed_packet to 32M (this line will already exist)

    max_allowed_packet = 32M

  14. Cam revised this gist Jun 25, 2015. 1 changed file with 11 additions and 4 deletions.
    15 changes: 11 additions & 4 deletions phabricator_readme.md
    Original file line number Diff line number Diff line change
    @@ -153,18 +153,25 @@ Make sure `mod_php` and `mod_rewrite` are enabled, and `mod_ssl` if you intend t
    ft_boolean_syntax=' |-><()~*:""&^'
    ft_stopword_file=/home/phd/phabricator/resources/sql/stopwords.txt
    ft_min_word_len=3

    This should be about 40% of the memory of the box:

    #### Wrap-up:
    innodb_buffer_pool_size=800M

    And also adjust max_allowed_packet to 32M

    ##### Configure MySQL
    max_allowed_packet = 32M

    #### Restart `mysql` and run phabricator storage upgrade:

    # service restart mysql
    ./bin/storage upgrade

    ##### Restart phd daemons (This must work for phd user):
    #### Restart phd daemons:

    ./bin/phd restart

    ##### Get the phabricator update script:
    #### Get the phabricator update script:

    wget http://www.phabricator.com/rsrc/install/update_phabricator.sh

  15. Cam revised this gist Jun 25, 2015. 1 changed file with 4 additions and 12 deletions.
    16 changes: 4 additions & 12 deletions phabricator_readme.md
    Original file line number Diff line number Diff line change
    @@ -154,25 +154,17 @@ Make sure `mod_php` and `mod_rewrite` are enabled, and `mod_ssl` if you intend t
    ft_stopword_file=/home/phd/phabricator/resources/sql/stopwords.txt
    ft_min_word_len=3

    #### All phabricator directories should be owned by the phd user:
    #### Wrap-up:

    root@bdr-gerrit-01:/home/phd# ls -l /home/phd
    total 20
    drwxr-xr-x 8 phd phd 4096 Jun 19 19:19 arcanist
    -rw-r--r-- 1 phd phd 2052 Jun 19 19:18 install_ubuntu.sh
    drwxr-xr-x 8 phd phd 4096 Jun 19 19:19 libphutil
    drwxr-xr-x 12 phd phd 4096 Jun 23 20:10 phabricator
    drwxrwxrwx 69 phd phd 4096 Jun 24 18:58 phabricator-files

    #### Configure MySQL
    ##### Configure MySQL

    ./bin/storage upgrade

    #### Restart phd daemons (This must work for phd user):
    ##### Restart phd daemons (This must work for phd user):

    ./bin/phd restart

    #### Get the phabricator update script:
    ##### Get the phabricator update script:

    wget http://www.phabricator.com/rsrc/install/update_phabricator.sh

  16. Cam revised this gist Jun 25, 2015. 1 changed file with 2 additions and 2 deletions.
    4 changes: 2 additions & 2 deletions phabricator_readme.md
    Original file line number Diff line number Diff line change
    @@ -178,6 +178,6 @@ Make sure `mod_php` and `mod_rewrite` are enabled, and `mod_ssl` if you intend t

    #### Refer to the phabricator configuration guide for next steps:

    At this point, you should be able to host and clone repositories via HTTP. Refer the the [Diffusion Hosting Configuration Guide](https://secure.phabricator.com/book/phabricator/article/diffusion_hosting/) to setup ssh repo hosting.
    At this point, you should be able to host and clone repositories via HTTP. Refer the the [Diffusion Hosting Configuration Guide](https://secure.phabricator.com/book/phabricator/article/diffusion_hosting/) to setup ssh repo access.

    Also see [General Phabricator Configuration Guide](https://secure.phabricator.com/book/phabricator/article/configuration_guide/) for additional advanced configuration steps.
    Also see the official [Phabricator Configuration Guide](https://secure.phabricator.com/book/phabricator/article/configuration_guide/) for additional advanced configuration steps.
  17. Cam revised this gist Jun 25, 2015. 1 changed file with 1 addition and 1 deletion.
    2 changes: 1 addition & 1 deletion phabricator_readme.md
    Original file line number Diff line number Diff line change
    @@ -1,7 +1,7 @@
    Phabricator Ubuntu Installation Guide
    -------------------------------------

    This is a supplement to the [official Phabricator Installation Guide](https://secure.phabricator.com/book/phabricator/article/installation_guide/), because their guide will leave you with all kinds of permission and config errors and ~15,000 setup issues on startup.
    This is a supplement to the official [Phabricator Installation Guide](https://secure.phabricator.com/book/phabricator/article/installation_guide/), because their guide will leave you with all kinds of permission and config errors and ~15,000 setup issues on startup.

    #### Install bonus packages:

  18. Cam revised this gist Jun 25, 2015. 1 changed file with 2 additions and 4 deletions.
    6 changes: 2 additions & 4 deletions phabricator_readme.md
    Original file line number Diff line number Diff line change
    @@ -178,8 +178,6 @@ Make sure `mod_php` and `mod_rewrite` are enabled, and `mod_ssl` if you intend t

    #### Refer to the phabricator configuration guide for next steps:

    General configuration:
    <https://secure.phabricator.com/book/phabricator/article/configuration_guide/>
    At this point, you should be able to host and clone repositories via HTTP. Refer the the [Diffusion Hosting Configuration Guide](https://secure.phabricator.com/book/phabricator/article/diffusion_hosting/) to setup ssh repo hosting.

    Repository hosting configuration:
    <https://secure.phabricator.com/book/phabricator/article/diffusion_hosting/>
    Also see [General Phabricator Configuration Guide](https://secure.phabricator.com/book/phabricator/article/configuration_guide/) for additional advanced configuration steps.
  19. Cam revised this gist Jun 25, 2015. 1 changed file with 3 additions and 3 deletions.
    6 changes: 3 additions & 3 deletions phabricator_readme.md
    Original file line number Diff line number Diff line change
    @@ -33,7 +33,7 @@ cd /home/phd/phabricator

    # Generally acceptable settings:
    ./bin/config set mysql.pass <MYSQL_ROOT_PASSWD>
    ./bin/config set phabricator.base-uri 'http://phabricator.eng.mydomain.net/'
    ./bin/config set phabricator.base-uri 'http://phabricator.mydomain.net/'
    ./bin/config set phd.user phd
    ./bin/config set environment.append-paths '["/usr/lib/git-core"]'
    ./bin/config set diffusion.ssh-user git
    @@ -77,8 +77,8 @@ then setup apache configuration file (see examples below) and enable phabricator
    # match this virtual host. For the default virtual host (this file) this
    # value is not decisive as it is used as a last resort host regardless.
    # However, you must set it for any further virtual host explicitly.
    ServerName phabricator.eng.mydomain.net
    ServerAlias phabricator.eng.mydomain.net
    ServerName phabricator.mydomain.net
    ServerAlias phabricator.mydomain.net
    ServerAdmin [email protected]

    DocumentRoot /home/phd/phabricator/webroot
  20. Cam revised this gist Jun 25, 2015. 1 changed file with 2 additions and 2 deletions.
    4 changes: 2 additions & 2 deletions phabricator_readme.md
    Original file line number Diff line number Diff line change
    @@ -5,11 +5,11 @@ This is a supplement to the [official Phabricator Installation Guide](https://se

    #### Install bonus packages:

    # apt-get install mercurial subversion zsh python-pygments sendmail imagemagick
    # apt-get install mercurial subversion python-pygments sendmail imagemagick

    #### Create necessary users and add phd-user to sudoers:

    # adduser phd --home /home/phd --shell /usr/bin/zsh
    # adduser phd --home /home/phd
    # adduser phd sudo
    # adduser git

  21. Cam revised this gist Jun 25, 2015. 1 changed file with 2 additions and 0 deletions.
    2 changes: 2 additions & 0 deletions phabricator_readme.md
    Original file line number Diff line number Diff line change
    @@ -141,6 +141,8 @@ And here is an example of an HTTPS-enabled phabricator conf:
    </VirtualHost>
    </IfModule>

    Make sure `mod_php` and `mod_rewrite` are enabled, and `mod_ssl` if you intend to set up SSL

    # a2dissite 000-default
    # a2ensite phabricator
    # service apache2 restart
  22. Cam revised this gist Jun 25, 2015. 1 changed file with 2 additions and 2 deletions.
    4 changes: 2 additions & 2 deletions phabricator_readme.md
    Original file line number Diff line number Diff line change
    @@ -129,13 +129,13 @@ And here is an example of an HTTPS-enabled phabricator conf:
    # out from GitHub when following the Installation Guide.
    #
    # Make sure you include "/webroot" at the end!
    DocumentRoot /etc/phabricator/webroot
    DocumentRoot /home/phd/phabricator/webroot

    RewriteEngine on
    RewriteRule ^/rsrc/(.*) - [L,QSA]
    RewriteRule ^/favicon.ico - [L,QSA]
    RewriteRule ^(.*)$ /index.php?__path__=$1 [B,L,QSA]
    <Directory "/etc/phabricator/webroot">
    <Directory "/home/phd/phabricator/webroot">
    Require all granted
    </Directory>
    </VirtualHost>
  23. Cam revised this gist Jun 25, 2015. 1 changed file with 2 additions and 2 deletions.
    4 changes: 2 additions & 2 deletions phabricator_readme.md
    Original file line number Diff line number Diff line change
    @@ -9,9 +9,9 @@ This is a supplement to the [official Phabricator Installation Guide](https://se

    #### Create necessary users and add phd-user to sudoers:

    # useradd phd --shell=/usr/bin/zsh
    # adduser phd --home /home/phd --shell /usr/bin/zsh
    # adduser phd sudo
    # useradd git
    # adduser git

    And create repo directory if phabricator will be hosting repos:

  24. Cam revised this gist Jun 25, 2015. 1 changed file with 1 addition and 1 deletion.
    2 changes: 1 addition & 1 deletion phabricator_readme.md
    Original file line number Diff line number Diff line change
    @@ -12,7 +12,7 @@ This is a supplement to the [official Phabricator Installation Guide](https://se
    # useradd phd --shell=/usr/bin/zsh
    # adduser phd sudo
    # useradd git

    And create repo directory if phabricator will be hosting repos:

    # mkdir /var/repo
  25. Cam revised this gist Jun 25, 2015. 1 changed file with 6 additions and 5 deletions.
    11 changes: 6 additions & 5 deletions phabricator_readme.md
    Original file line number Diff line number Diff line change
    @@ -12,6 +12,12 @@ This is a supplement to the [official Phabricator Installation Guide](https://se
    # useradd phd --shell=/usr/bin/zsh
    # adduser phd sudo
    # useradd git

    And create repo directory if phabricator will be hosting repos:

    # mkdir /var/repo
    # chown -R phd /var/repo
    # chgrp -R phd /var/repo

    #### Install phabricator:

    @@ -146,11 +152,6 @@ And here is an example of an HTTPS-enabled phabricator conf:
    ft_stopword_file=/home/phd/phabricator/resources/sql/stopwords.txt
    ft_min_word_len=3

    #### phd user needs to have ownership of a directory created at /var/repo:

    root@bdr-gerrit-01:/var# ll /var | grep repo
    drwxr-xr-x 7 phd phd 4096 Jun 23 20:38 repo/

    #### All phabricator directories should be owned by the phd user:

    root@bdr-gerrit-01:/home/phd# ls -l /home/phd
  26. Cam revised this gist Jun 24, 2015. 1 changed file with 1 addition and 0 deletions.
    1 change: 1 addition & 0 deletions phabricator_readme.md
    Original file line number Diff line number Diff line change
    @@ -31,6 +31,7 @@ cd /home/phd/phabricator
    ./bin/config set phd.user phd
    ./bin/config set environment.append-paths '["/usr/lib/git-core"]'
    ./bin/config set diffusion.ssh-user git
    ./bin/config set pygments.enabled true

    # for local-disk file storage only:
    mkdir /home/phd/phabricator-files
  27. Cam revised this gist Jun 24, 2015. 1 changed file with 13 additions and 13 deletions.
    26 changes: 13 additions & 13 deletions phabricator_readme.md
    Original file line number Diff line number Diff line change
    @@ -1,26 +1,26 @@
    Phabricator Ubuntu Installation Guide
    -------------------------------------

    This is a supplement to the [official Phabricator Installation Guide](https://secure.phabricator.com/book/phabricator/article/installation_guide/), because their guide will leave you with all kinds of permission and config errors.
    This is a supplement to the [official Phabricator Installation Guide](https://secure.phabricator.com/book/phabricator/article/installation_guide/), because their guide will leave you with all kinds of permission and config errors and ~15,000 setup issues on startup.

    #### Install bonus packages:

    # apt-get install mercurial subversion zsh python-pygments sendmail imagemagick

    ### Create necessary users and add phd-user to sudoers:
    #### Create necessary users and add phd-user to sudoers:

    # useradd phd --shell=/usr/bin/zsh
    # adduser phd sudo
    # useradd git

    ### Install phabricator:
    #### Install phabricator:

    su phd
    cd /home/phd
    wget http://www.phabricator.com/rsrc/install/install_ubuntu.sh
    bash install_ubuntu.sh

    ### Recommended Phabricator Configurations to set:
    #### Recommended Phabricator Configurations to set:

    ```bash
    cd /home/phd/phabricator
    @@ -51,12 +51,12 @@ chmod -R 755 /home/phd/phabricator-files
    ./bin/config set remarkup.enable-embedded-youtube true
    ```

    ### This needs to be appended to `/etc/sudoers` (NOTE: verify your binary locations):
    #### This needs to be appended to `/etc/sudoers` (NOTE: verify your binary locations):

    git ALL=(phd) SETENV: NOPASSWD: /usr/bin/git-upload-pack, /usr/bin/git-receive-pack, /usr/bin/hg, /usr/bin/svnserve
    www-data ALL=(phd) SETENV: NOPASSWD: /usr/bin/git-upload-pack, /usr/lib/git-core/git-http-backend, /usr/bin/hg

    ### Apache Configuration:
    #### Apache Configuration:

    First verify that apache is displaying a default page on port 80,
    then setup apache configuration file (see examples below) and enable phabricator site:
    @@ -138,19 +138,19 @@ And here is an example of an HTTPS-enabled phabricator conf:
    # a2ensite phabricator
    # service apache2 restart

    ### Add these lines to /etc/mysql/my.cnf under the [mysqld] heading:
    #### Add these lines to /etc/mysql/my.cnf under the [mysqld] heading:

    sql_mode=STRICT_ALL_TABLES
    ft_boolean_syntax=' |-><()~*:""&^'
    ft_stopword_file=/home/phd/phabricator/resources/sql/stopwords.txt
    ft_min_word_len=3

    ### phd user needs to have ownership of a directory created at /var/repo:
    #### phd user needs to have ownership of a directory created at /var/repo:

    root@bdr-gerrit-01:/var# ll /var | grep repo
    drwxr-xr-x 7 phd phd 4096 Jun 23 20:38 repo/

    ### All phabricator directories should be owned by the phd user:
    #### All phabricator directories should be owned by the phd user:

    root@bdr-gerrit-01:/home/phd# ls -l /home/phd
    total 20
    @@ -160,19 +160,19 @@ And here is an example of an HTTPS-enabled phabricator conf:
    drwxr-xr-x 12 phd phd 4096 Jun 23 20:10 phabricator
    drwxrwxrwx 69 phd phd 4096 Jun 24 18:58 phabricator-files

    ### Configure MySQL
    #### Configure MySQL

    ./bin/storage upgrade

    ### Restart phd daemons (This must work for phd user):
    #### Restart phd daemons (This must work for phd user):

    ./bin/phd restart

    ### Get the phabricator update script:
    #### Get the phabricator update script:

    wget http://www.phabricator.com/rsrc/install/update_phabricator.sh

    ### Refer to the phabricator configuration guide for next steps:
    #### Refer to the phabricator configuration guide for next steps:

    General configuration:
    <https://secure.phabricator.com/book/phabricator/article/configuration_guide/>
  28. Cam revised this gist Jun 24, 2015. 1 changed file with 1 addition and 1 deletion.
    2 changes: 1 addition & 1 deletion phabricator_readme.md
    Original file line number Diff line number Diff line change
    @@ -3,7 +3,7 @@ Phabricator Ubuntu Installation Guide

    This is a supplement to the [official Phabricator Installation Guide](https://secure.phabricator.com/book/phabricator/article/installation_guide/), because their guide will leave you with all kinds of permission and config errors.

    ### Install bonus packages:
    #### Install bonus packages:

    # apt-get install mercurial subversion zsh python-pygments sendmail imagemagick

  29. Cam revised this gist Jun 24, 2015. 1 changed file with 1 addition and 1 deletion.
    2 changes: 1 addition & 1 deletion phabricator_readme.md
    Original file line number Diff line number Diff line change
    @@ -5,7 +5,7 @@ This is a supplement to the [official Phabricator Installation Guide](https://se

    ### Install bonus packages:

    # apt-get install mercurial subversion zsh python-pygments sendmail
    # apt-get install mercurial subversion zsh python-pygments sendmail imagemagick

    ### Create necessary users and add phd-user to sudoers:

  30. Cam revised this gist Jun 24, 2015. 1 changed file with 28 additions and 23 deletions.
    51 changes: 28 additions & 23 deletions phabricator_readme.md
    Original file line number Diff line number Diff line change
    @@ -22,29 +22,34 @@ This is a supplement to the [official Phabricator Installation Guide](https://se

    ### Recommended Phabricator Configurations to set:

    ```bash
    mkdir /home/phd/phabricator-files
    chmod -R 755 /home/phd/phabricator-files
    cd /home/phd/phabricator
    ./bin/config set mysql.pass <MYSQL_ROOT_PASSWD>
    ./bin/config set phabricator.base-uri 'http://phabricator.eng.mydomain.net/'
    # Only if you would like to use local-disk storage for files:
    ./bin/config set storage.local-disk.path /home/phd/phabricator-files
    ./bin/config set phd.user phd
    # For SSH access (this will need additional configuration)
    ./bin/config set diffusion.ssh-user git
    ./bin/config set environment.append-paths '["/usr/lib/git-core"]'
    # Only set true if you want to allow public http cloning:
    ./bin/config set policy.allow-public true
    # Set to true if you want to allow http pushes
    ./bin/config set diffusion.allow-http-auth false
    ./bin/config set phabricator.show-prototypes true
    # You may want this true, depending on your workflow:
    ./bin/config set differential.require-test-plan-field false
    # recommended silliness-enabling settings:
    ./bin/config set files.enable-imagemagick true
    ./bin/config set remarkup.enable-embedded-youtube true
    ```
    ```bash
    cd /home/phd/phabricator

    # Generally acceptable settings:
    ./bin/config set mysql.pass <MYSQL_ROOT_PASSWD>
    ./bin/config set phabricator.base-uri 'http://phabricator.eng.mydomain.net/'
    ./bin/config set phd.user phd
    ./bin/config set environment.append-paths '["/usr/lib/git-core"]'
    ./bin/config set diffusion.ssh-user git

    # for local-disk file storage only:
    mkdir /home/phd/phabricator-files
    chmod -R 755 /home/phd/phabricator-files
    ./bin/config set storage.local-disk.path /home/phd/phabricator-files

    # Set true if you want to allow public http cloning:
    ./bin/config set policy.allow-public true
    # Set to true if you want to allow http pushes
    ./bin/config set diffusion.allow-http-auth false
    # You most likely want prototype apps, they are very useful:
    ./bin/config set phabricator.show-prototypes true
    # You may want this true, depending on your workflow:
    ./bin/config set differential.require-test-plan-field false

    # recommended silliness-enabling settings:
    ./bin/config set files.enable-imagemagick true
    ./bin/config set remarkup.enable-embedded-youtube true
    ```

    ### This needs to be appended to `/etc/sudoers` (NOTE: verify your binary locations):