openbsd-ports/www/rackmonkey/patches/patch-doc_install_txt
sthen d74acfc493 import ports/www/rackmonkey, feedback/ok jasper@. requires up-to-date
infrastructure/mk/bsd.port.mk to fix pkg-readmes ownership.

RackMonkey is a tool for managing racks of equipment such as servers
and switches. You can keep track of what's where, which OS it runs,
who it belongs to and what it's used for. RackMonkey quickly finds
any device and draws a rack diagram of its location.
2010-10-28 14:33:54 +00:00

73 lines
3.0 KiB
Plaintext

$OpenBSD: patch-doc_install_txt,v 1.1.1.1 2010/10/28 14:33:54 sthen Exp $
--- doc/install.txt.orig Sun Sep 13 12:21:15 2009
+++ doc/install.txt Thu Oct 28 14:13:35 2010
@@ -142,6 +142,16 @@ settings for http://<yourserver>/rackmonkey. If you ar
RackMonkey from this location then you can simply include the configuration
snippet in your Apache configuration as follows.
+OpenBSD (from packages)
+-----------------------
+Symlink httpd-rackmonkey.conf into /var/www/conf/modules:
+
+ # cd /var/www/conf/modules && ln -s ../modules.sample/httpd-rackmonkey.conf
+
+Then reload apache:
+
+ # apachectl stop; apachectl start
+
Linux
-----
On most Linux distributions you can configure Apache by copying
@@ -213,9 +223,10 @@ on running CGI applications.
5. Configuring RackMonkey
=========================
Configuration is stored in a text file, which is read from
-/etc/rackmonkey.conf by default. If you're happy with this location, simply
-copy conf/rackmonkey.conf-default to /etc/rackmonkey.conf and proceed to the
-'Editing Configuration' section (below).
+/conf/rackmonkey.conf by default (to suit OpenBSD httpd running in
+a chroot jail). If you use 'httpd -u' to disable the chroot, follow the
+next section to change the path to /var/www/conf/rackmonkey.conf.
+Otherwise proceed to the 'Editing Configuration' section (below).
NB. If you're using Postgres or MySQL, this configuration file may contain
your database username and password. For maximum security only root (or the
@@ -264,7 +275,8 @@ example if you want your database to reside in /home/r
NB. This path must be writable by the web server and should not be within
web space, or users will be able to download your database. As we're using
SQLite you can leave the DBUSER and DBPASS values blank. Make sure the
-'SQLite' in the dbconnect string is in the case shown.
+'SQLite' in the dbconnect string is in the case shown. The OpenBSD
+package sets this to a writable directory by default.
For Postgres
------------
@@ -339,17 +351,24 @@ it includes common companies, device roles and operati
For SQLite
----------
+Note that the OpenBSD package provides a pre-configured base database
+for SQLite.
+
Make a note of the path you specified for 'dbconnect' in section 5, then run
following commands:
- $ sqlite3 [PATH] < sql/schema/schema.sqlite.sql
- $ sqlite3 [PATH] < sql/data/default_data.sql
- $ sqlite3 [PATH] < sql/data/sample_data.sql
+ $ cd /var/www/rackmonkey
+ $ DBPATH=db/rackmonkey.db
+ $ sqlite3 $DBPATH < sql/schema/schema.sqlite.sql
+ $ sqlite3 $DBPATH < sql/data/default_data.sql
+ $ sqlite3 $DBPATH < sql/data/sample_data.sql
You should then change the permissions of the database file and its parent
directory to be readable and writable by your web server. For example, you
might change the owner to 'www' if that is the user your web server runs
under.
+
+ $ chown root:www $DBPATH; chmod 770 ${DBPATH}
For further information on administering SQLite see:
http://www.sqlite.org/docs.html.