Dear PhabricatorS,
I'm sorry this is probably a newby question, but I can't find a solution or, better, I found some docs on the internet, applied all suggestions but they did not work for me.
In our organization we are evaluating Phabricator and, being the best tool we have tested so far, I'm willing to have it perfectly functional in all the required parts in order to have it approved for everyday use by CTO.
Problem: pygmentize is not working on my setup.
Setup:
Server: VMWare VM Ubuntu Server 14.04
DB: MySQL
Phabricator: installed in /var/opt/phabricator
Webserver. Apache2 installed using apt-get of ubuntu server and modifying the config as required by Phabricator docs
diego@ServerLinux1:/var/opt/phabricator/phabricator$ ps axu [snip!] mysql 1047 0.0 8.1 889516 167984 ? Ssl Sep29 1:18 /usr/sbin/mysqld root 1150 0.0 0.2 91772 4636 ? S Sep29 0:44 /usr/sbin/vmtoolsd memcache 1258 0.0 0.0 325396 1184 ? Sl Sep29 0:01 /usr/bin/memcached -m 64 -p 11211 -u memcache -l 127.0.0.1 root 1358 0.0 0.0 25344 1676 ? Ss Sep29 0:00 /usr/lib/postfix/master postfix 1367 0.0 0.0 27460 1552 ? S Sep29 0:00 qmgr -l -t unix -u root 1536 0.0 0.8 416980 18088 ? Ss Sep29 0:01 /usr/sbin/apache2 -k start www-data 1540 0.0 3.3 447232 69112 ? S Sep29 0:22 /usr/sbin/apache2 -k start www-data 1541 0.0 2.9 440224 60732 ? S Sep29 0:06 /usr/sbin/apache2 -k start www-data 1543 0.0 3.7 454808 76200 ? S Sep29 0:30 /usr/sbin/apache2 -k start root 1602 0.0 0.0 14540 960 tty1 Ss+ Sep29 0:00 /sbin/getty -8 38400 tty1 root 1631 0.0 0.0 0 0 ? S Sep29 0:00 [kauditd] www-data 1775 0.0 2.4 431512 50672 ? S Sep29 0:33 /usr/sbin/apache2 -k start www-data 1776 0.0 2.7 435016 56236 ? S Sep29 0:24 /usr/sbin/apache2 -k start www-data 1777 0.0 2.8 439920 58748 ? S Sep29 0:23 /usr/sbin/apache2 -k start www-data 1779 0.0 2.5 429736 52196 ? S Sep29 0:12 /usr/sbin/apache2 -k start www-data 1780 0.0 3.0 440132 62188 ? S Sep29 0:07 /usr/sbin/apache2 -k start root 5352 0.0 1.0 276860 21432 ? S Sep29 0:25 php ./phd-daemon PhabricatorRepositoryPullLocalDaemon --daemonize --log=/var/tmp/phd/log/daemons.log --phd=/var/tmp/phd/pid root 5353 0.0 1.3 278592 28036 ? Ss Sep29 1:02 php ./exec_daemon.php PhabricatorRepositoryPullLocalDaemon --load-phutil-library=/var/opt/phabricator/arcanist/src --load-phutil-library=/var/opt/phabricator/phabricator/src --log=/var/tmp/phd/log/daemons.l root 5361 0.0 1.0 276860 21420 ? S Sep29 0:16 php ./phd-daemon PhabricatorGarbageCollectorDaemon --daemonize --log=/var/tmp/phd/log/daemons.log --phd=/var/tmp/phd/pid root 5362 0.0 1.4 279544 29212 ? Ss Sep29 0:00 php ./exec_daemon.php PhabricatorGarbageCollectorDaemon --load-phutil-library=/var/opt/phabricator/arcanist/src --load-phutil-library=/var/opt/phabricator/phabricator/src --log=/var/tmp/phd/log/daemons.log root 5380 0.0 1.0 276860 21424 ? S Sep29 0:16 php ./phd-daemon PhabricatorTaskmasterDaemon --daemonize --log=/var/tmp/phd/log/daemons.log --phd=/var/tmp/phd/pid root 5381 0.0 2.8 310320 57964 ? Ss Sep29 0:10 php ./exec_daemon.php PhabricatorTaskmasterDaemon --load-phutil-library=/var/opt/phabricator/arcanist/src --load-phutil-library=/var/opt/phabricator/phabricator/src --log=/var/tmp/phd/log/daemons.log -- root 5392 0.0 1.0 276860 21428 ? S Sep29 0:15 php ./phd-daemon PhabricatorTaskmasterDaemon --daemonize --log=/var/tmp/phd/log/daemons.log --phd=/var/tmp/phd/pid root 5393 0.0 2.7 307864 55908 ? Ss Sep29 0:12 php ./exec_daemon.php PhabricatorTaskmasterDaemon --load-phutil-library=/var/opt/phabricator/arcanist/src --load-phutil-library=/var/opt/phabricator/phabricator/src --log=/var/tmp/phd/log/daemons.log -- root 5397 0.0 1.0 276860 21428 ? S Sep29 0:15 php ./phd-daemon PhabricatorTaskmasterDaemon --daemonize --log=/var/tmp/phd/log/daemons.log --phd=/var/tmp/phd/pid root 5398 0.0 2.7 308776 56980 ? Ss Sep29 0:11 php ./exec_daemon.php PhabricatorTaskmasterDaemon --load-phutil-library=/var/opt/phabricator/arcanist/src --load-phutil-library=/var/opt/phabricator/phabricator/src --log=/var/tmp/phd/log/daemons.log -- root 5402 0.0 1.0 276860 21432 ? S Sep29 0:15 php ./phd-daemon PhabricatorTaskmasterDaemon --daemonize --log=/var/tmp/phd/log/daemons.log --phd=/var/tmp/phd/pid root 5403 0.0 2.9 312444 60496 ? Ss Sep29 0:10 php ./exec_daemon.php PhabricatorTaskmasterDaemon --load-phutil-library=/var/opt/phabricator/arcanist/src --load-phutil-library=/var/opt/phabricator/phabricator/src --log=/var/tmp/phd/log/daemons.log -- www-data 6077 0.0 2.2 426980 45576 ? S Sep29 0:04 /usr/sbin/apache2 -k start root 6694 0.0 0.0 0 0 ? S 01:37 0:01 [kworker/u2:3] root 12347 0.0 0.2 105628 4336 ? Ss 10:56 0:00 sshd: diego [priv] diego 12437 0.0 0.1 105628 2100 ? S 10:56 0:00 sshd: diego@pts/0 diego 12438 0.0 0.2 22096 4692 pts/0 Ss 10:56 0:00 -bash www-data 15073 0.0 1.4 420860 29804 ? S 12:32 0:00 /usr/sbin/apache2 -k start postfix 16471 0.0 0.0 27408 1520 ? S 13:20 0:00 pickup -l -t unix -u -c diego 18643 0.0 0.0 17168 1288 pts/0 R+ 14:37 0:00 ps axu
Pygments: last version 1.6 with a modified lexer to correctly "pygmentize" my assembly files (verified it is functioning properly). Pygmentize installed in /usr/local/bin:
diego@ServerLinux1:/var/opt/phabricator/phabricator$ ls /usr/local/bin/pygmentize -l -rwxr-xr-x 1 root root 304 Sep 26 17:12 /usr/local/bin/pygmentize diego@ServerLinux1:/var/opt/phabricator/phabricator$
Added the '/usr/local/bin' path to phabricator configuration, as required using the comment:
sudo ./bin/config set environment.append-paths '["/usr/local/bin"]'
And the result is this:
diego@ServerLinux1:/var/opt/phabricator/phabricator$ ./bin/config get environment.append-paths { "config" : [ { "key" : "environment.append-paths", "source" : "local", "value" : [ "\/usr\/local\/bin" ] } ] }
Verified the path /usr/local/bin is present in $PATH variable of www-data user (running Apache):
diego@ServerLinux1:/var/opt/phabricator/phabricator$ sudo -u www-data printenv PATH /usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin diego@ServerLinux1:/var/opt/phabricator/phabricator$
Verified one task running apache2 has correct environment:
diego@ServerLinux1:/var/opt/phabricator/phabricator$ sudo cat /proc/1775/environ APACHE_RUN_DIR=/var/run/apache2APACHE_PID_FILE=/var/run/apache2/apache2.pidPATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/local/binAPACHE_LOCK_DIR=/var/lock/apache2LANG=CAPACHE_RUN_USER=www-dataAPACHE_RUN_GROUP=www-dataAPACHE_LOG_DIR=/var/log/apache2PWD=/diego@ServerLinux1:/var/opt/phabricator/phabricator$
Verified the user www-data can run pygmentize:
diego@ServerLinux1:/var/opt/phabricator/phabricator$ sudo -u www-data pygmentize -V Pygments version 1.6, (c) 2006-2013 by Georg Brandl. diego@ServerLinux1:/var/opt/phabricator/phabricator$
Enabled Pygments from the configuration, restarted phd and ...
The Phabricator is still complaining that pygmentize cannot be found in current path...
WHERE AM I WRONG? :-(
Thank you very much, kudos for your great software!
Diego