PerServ is no longer available. Continue at

https://dairgram.com

for a successor. Outline has been extended and Port Mgr simplified. Hydra and Tmsgp are removed. A python-centric platform for writing web pages is added.


PerServ - install example


Overall file structure

Example is a dynamic PerServ package which serves as a template for your own app development. It is distributed as with PerServ. It's directory tree looks like this:
          .
          .
          +-- dyn
               |
               +-- example
                      |
                      +-- app_icon.gif
                      +-- app_icon.png
                      +-- example.py

The name of the directory and main python program (py extension) are both identically "example". To make your own distributable app, copy the example directory to, say, "myownapp" and change all occurrences in file/directory names and internally of "example" to "myownapp". This means you will have to find and replace all instances of "example" inside dyn >> myownapp >> myownapp.py to "myownapp". The dyn directory now looks like this:

          .
          .
          +-- dyn
               |
               +-- example
               |      |
                      +-- app_icon.gif
               |      +-- app_icon.png
               |      +-- example.py
               |
               +-- myownapp
                      |
                      +-- app_icon.gif
                      +-- app_icon.png
                      +-- myownapp.py
If you do not see myownapp, reboot the server. Note that the identification of myownapp on menu is "Myowna". The menu identification is truncated at first 6-7 characters of directory name.

Just to make sure we are clear here, we are using the string "myownapp" to stand in for the real name of your app in order to simplify the discussion. Don't name your app this. Pick a meaningful name.

app_icon.png and app_icon.png

The app_icon.png and app_icon.gif file under myownapp are square images 48x48 pixels or greater.

myownapp.py

The entry point in myownapp.py has the fixed name myownapp_init(). The psdyn.py file contains definition of utility routines and constants. All definitions start with "psd_" and this prefix is reserved for system defined names. See the global_psd.py import file at [perserv]/prg3/bin/global_psd.py for complete list.

We recommend that the routines named webpage_entry and resident_scan are good candidates for moving to separate modules. Names of those modules should incorporate the name of your app as a prefix so that there is no name collision with other authors or DAIR Systems LLC.