I know what you're thinking! Yes, git is installed, I am on origin/master, and my file permissions are a-okay.
To preface, I'm on FreeBSD 13.2-RELEASE-p8, Apache 2.4, MySQL Ver 15.1 Distrib 10.6.16-MariaDB, and PHP 8.2.14. Despite my strange setup, ITFlow runs just how you would expect, about 99% of the features work (missing whois
because the syntax is different in FreeBSD, might open a (pull) request someday.)
Now onto my actual problem, I cannot update ITFlow from the admin_update.php webpage. I still can update via git from the CLI normally, just not from the webpage. The actual error that returns is "Error details:- sh: git: not found". Now I'm pretty sure this is because it can't find git
in my PATH environment variable.
So,httpd
runs as user www
on FreeBSD. I checked the admin_debug.php page, the PATH enironment variable is /sbin:/bin:/usr/sbin:/usr/bin
. Typically, this would be fine, however git is in /usr/local/bin/git
, so I need to add /usr/local/bin
to the PATH.
I tried switching to user www
, however it is a "nologin" user account, so I can't set the variable from the shell or a .profile
.
I tried making a symlink ln -s /usr/local/bin/git /usr/bin/git
, but because this is running in a jail, /usr/bin
is mounted read-only, so it fails, even as root.
Next, I figured the I could set the PATH var somewhere in the Apache or PHP configs, but not sure where? Anyone know how I can move forward?
Thanks for your awesome software!