vfront configuration

Print Friendly, PDF & Email

Vfront is a web-based front-end to a database.  You set it up as a kind of viewer for a particular database.  For example, if you have a MySQL database of your music collection, with tables like “albums,” “songs,” and “artists” you could view those tables and even edit them via a convenient web interface.

Find more from the vfront home page.  There’s a nice demo of the music database example there.

The vfront system is designed to view *one* database.  (I didn’t understand this at first.)  It’s also designed to be separate from your database, so as to not interfere.  Thus, if your music database is stored in MySQL as mymusic, the vfront tables are stored in a separate MySQL database called mymusic_vfront.  Of course, that new database needs to be created and have a user with access privileges.  The vfront installed will create the database for you, but you’ll need to supply (1) the root password so that the database can be created, and (2) the username and password that you use to access your mymusic database.

The vfront system has a cool automatic installer.  The basic idea is:

  1. Unpack the tar.gz file where you want the vfront SW to live.  This should be in some directory accessible via the web.  Furthermore, some of those directories will need to be writable by the web server (Apache).  The top level directory has an index.php file; that’s the one that runs the system.  Also in that top level directory is a subdirectory called _install; that’s where the installer lives.
  2. Using a browser, navigate to http://yourserver.tld/path/to/vfront/_install/index.php (I didn’t understand this at first.)
  3. The first page just asks for the language you want to use (vfront is internationalized and handles both Italian and English.) and asks you to agree to the license.
  4. Next it analyzes the installation directory and complains about any incorrect permissions and such.  You should fix those by hand and just reload the page until you get all green.
  5. Finally, you get to step 1 of 3.  It’ll ask you questions like the name of the database you want to monitor, the username and password that gives you access.  It’ll make up a name for the other database, by appending “_vfront” to the name of your database.  (You can change this default, if desired.) Be sure to use the “test connection” button until you get a green approval that the connection works.
  6. Step 2 of 3 asks you for the root password for your MySQL server.  Once you give that, it can create the database and set things up for you.
  7. In step 3 of 3 you’ll also have to give the email address and password for the administrator of this instance of vfront.  For us, I’m mostly making myself the administrator.

Once you have completed the automatic installer, you’ll need to delete the _install subdirectory tree.  (This prevents someone else from re-installing and overwriting your installation.)  You can do this with a simple “rm -rf _install”; the automatic installer does not do this.

Next, point your web browser to http://yourserver.tld/path/to/vfront/index.php and you’ll be ready to start using vfront.  You can login with the administrator username and password you created earlier.  However, if you look at the list of tables, it’ll say “no tables are available,” which is *disappointing*, to say the least.  However, vfront has all kinds of security rules that you can make use of, allow certain users to view the data while others can edit or delete it.  By default, even the administrator can’t see any tables.  (I think this is a foolish default, since the administrator can grant themselves access to the tables, but that’s a minor criticism of some pretty good software.  However, they make it easy to fix this by providing a link next to the “no tables” message that takes you directly to the steps below.)

So, you should first allow the admin to view all tables:

  1. Go to vfront/index.php and log in with admin email and password
  2. click on “administration” in the upper right
  3. click on the “registries menu” link
  4. click on the link for “administer” for row with gid 0.  (Permissions are done for groups, and gid is the group id.)
  5. This will list all the tables and the permissions this group has for each one.  But modifying all of them individually is tedious so
  6. click on “quick functions” which allows shortcuts that apply to all tables, then
  7. in the row for “visibility,” click on “allow from all tables.”

You should also create some non-admin users:

In the upper right of the administration page, click on “DB User settings” and then “create new user”

 

 

 

2 Responses to vfront configuration

Leave a Reply

Your email address will not be published. Required fields are marked *