Apple OS X Installation

From DocMGR

Jump to: navigation, search

Contents

[edit] Introduction

I have now managed to install docMGR on;

  • 10.4 (Tiger) Client
  • 10.5 (Leopard) Client

I thought I would try and document the process. I used the other unix based installation instructions on the wiki as a guide and starting point. You might have a different way or disagree with my choices of tools - these work for me and are all free.

[edit] Assumptions

I have written this assuming the following;

  • You will read the installation instructions for the different parts needed.
  • You can use the terminal, even in a very basic way - if not google and find out.

Looking at the requirements for docMGR, we are going to need to install items that are not in OS X as standard - but there are many ways to do this.

[edit] What is needed, by isn't in OS X

  • Apache 1.3

is supported and comes preinstalled on both 10.4 and 10.5

  • PHP5 is needed

This is not pre-installed on OS X - the easiest way to get this installed is to go to Mark Liyanage's website [1] - follow the excellent instructions on his website, download, etc.

  • PostgresSQL is also needed

Again there is an excellent installer (with client tools) over at druware (files hosted on sourceforge) [2]

  • I also downloaded phppgadmin [3] to administer PostgresSQL, it makes adding a database and uploading the population script very easy.
  • Smultron is a very good plain text editor for editing .php and config files, download it - [4]

[edit] nix Extras

We are going to need to install a few extra utiliities;

  • gocr
  • xpdf
  • antiword
  • imagemagick
  • zlib
  • libjpeg
  • libpng
  • libtiff
  • libconv

You can use either Fink or MacPorts (your choice), I find MacPorts has a good range of ports.

  • Download MacPorts [5]
  • There is also an excellent GUI wrapper for Macports called Porticus [6] - download this as well.

Lastly download the latest docMGR package.

[edit] Download and Install, Groundwork

Start out by downloading everything, then install;

  • Install PHP5 - make the test.php file as described on Mark's website,
  • Restart Apache, you can do this via terminal or using System Preferences (it is under System Preferences>Sharing), just use the check box to toggle it off, it will stop, toggle it on - it starts.
  • Navigate to test.php - depending on where you placed it (i) http://localhost/test.php or (ii) in your user folder /~username/test.php - sure it is running fine.
  • Install PostgreSQL
  • Install MacPorts, access it via Porticus
  • Install the utilities, their dependancies will be automatically loaded, compiled and installed.

[edit] Download and Install, Configuration

We need to install phppgadmin;

  • Open up /Library/WebServer/Documents and place the tar file in.
  • Decompress it, and you will have a folder called "phppgadmin"

If you try and enter now you will get the following warning and refusal - "Login disallowed for security"

From the FAQ, we find the answer and resolution

Q: For some users I get a "Login disallowed for security" message.

A: Logins via phpPgAdmin with no password or certain usernames (pgsql, postgres, root, administrator) are denied by default. Before changing this behaviour (setting $conf['extra_login_security'] to false in the config.inc.php file) please read the PostgreSQL documentation about client authentication and understand how to change PostgreSQL's pg_hba.conf to enable passworded local connections.

- by default our installation of PostgreSQL has no password, phppgadmin does not like this - so alter the config file as follows;

  • Go into the folder called conf.
  • Duplicate the file called "config.inc.php- just incase you mess up the file. Then open the original in Smultron.
  • Look for "'extra_login_security", change the associated value to false, save the file and exit.

You are now in a position to get docMGR installed.

  • Open up /Library/WebServer/Documents and place the tar file in.
  • Decompress it, and you will have a folder called "doc"

Install the database using phpPgAdmin, create a new database called "docmgr", select the SQL section, select the .pgsql script from doc/scripts/docmgr.pgsql and execute. This will populate the database. You also need to edit the config file for docMGR, this is easily located within /doc/config/config.php - you will see that DB_PASSWORD needs to be blank, matching the blank password from the previous section.

  • Once everything is working, you need to go back and allocate permissions properly for your PostgreSQL database, user and passwords, then make your config files match - otherwise you are exposing your installation needlessly.

[edit] In Conclusion

Now you can switch back to the instructions in the main wiki to finish off the installation of docMGR- you need to use the Terminal to allocate permissions. I will supplement this article later (it had taken a little longer to write than I expected).

Personal tools