tacacsgui / tgui_install

Installation script for TacacsGUI
GNU General Public License v3.0
21 stars 9 forks source link

how to change database for tacacsgui and use postgresql not mysql to start tacacsgui #16

Open J1nDi opened 2 years ago

J1nDi commented 2 years ago
  1. I have a docker images which can successfully run tacacsgui and it's database(tgui,tgui_log) is a remote DB, not local. I changed the /opt/tacacsgui/web/api/config.php, to make DB_HOST become anther db that is also a docker and they are in the same docker bridge , then run systemctl apache2 restart, last check the web interfaces got server error without input anything.
  2. If I want to use postgresql to start tacacsgui, how to change the configfile?
bhaukaalbaba commented 1 year ago

1. That is because the installer fails to create the tgui_user in mysql database. You can do so by logging in as root by vieweing the password from /opt/tacacsgui/web/api/config.php. Be sure to run the following command.

Create the user tgui_user

Create user 'tgui_user'@'localhost' IDENTIFIED WITH mysql_native_password BY 'the password you saw in the config file';

Grant necessary permissions to run the application

GRANT ALL ON tgui.* TO 'tgui_user'@'localhost' GRANT ALL ON tgui_log.* TO 'tgui_user'@'localhost'

2. I haven't personally tried it yet but I might tinker around. If I succeed, I will let you know.