diff --git a/README.txt b/README.txt index cac912564d3266cee8756be7b9680655f0047918..4688a6e37524aad40d86b65f2ec2625a8fdd518e 100644 --- a/README.txt +++ b/README.txt @@ -3,7 +3,8 @@ Install Cloudooo $ python2.6 setup.py install - Warning: you must have installed setuptools>=0.6c11 in this python. + Warnings: + - you must have installed setuptools>=0.6c11 in this python. Install Dependencies in Mandriva ================================ @@ -38,12 +39,12 @@ Create Configuration File ========================= The configuration file is used to start the application using paster. - $ cp ./cloudooo/samples/cloudooo.conf . # Copy to current folder + $ cp ./cloudooo/samples/samples.conf . # Copy to current folder The next step is define some attributes in cloudooo.conf: - + - working_path - folder to run the application. This folder need be created. - uno_path - full path to UNO library; - - soffice_bin_path - full path to soffice.bin; + - soffice_binary_path - full path to soffice.bin; Run Application =============== diff --git a/cloudooo/mimemapper.py b/cloudooo/mimemapper.py index 8a540fa3e1fd46dbf6afc57b4353366ec50606a6..aefafe8f4dfa704206be7ee75c6c8f0d001599ff 100644 --- a/cloudooo/mimemapper.py +++ b/cloudooo/mimemapper.py @@ -106,7 +106,7 @@ class MimeMapper(object): office_binary_path = kw.get("office_binary_path", environ.get('office_binary_path')) command = [python_path , "'-c'" - , "'from cloudooo.bin.unomimemapper import main;main()'" + , "'from cloudooo.bin.unomimemapper import main;main()'" , "'--uno_path=%s'" % uno_path , "'--office_binary_path=%s'" % office_binary_path , "'--hostname=%s'" % hostname, "--port=%s" % port] diff --git a/cloudooo/samples/cloudooo.conf b/cloudooo/samples/cloudooo.conf index 363964f89079e64708dbbb623db7e8f3177122e7..f57d70a625704242c3133d5002c81ebc771d3bcf 100644 --- a/cloudooo/samples/cloudooo.conf +++ b/cloudooo/samples/cloudooo.conf @@ -7,41 +7,41 @@ debug_mode = True # Folder where pid files, lock files and virtual frame buffer mappings # are stored. In this folder is necessary create a folder tmp, because this # folder is used to create all temporary documents. -working_path = @WORKING_PATH@ +working_path = /hd/cloudooo/run # Folder where OpenOffice Uno interpreter is installed -uno_path = @UNO_PATH@ +uno_path = /opt/openoffice.org3/basis-link/program # Folder where OpenOffice Binarie is installed -office_binary_path = @OFFICE_BINARY_PATH@ +office_binary_path = /opt/openoffice.org3/program # ## Monitor Settings # # Limit to use the Openoffice Instance. if pass of the limit, the instance is # stopped and another is started. -limit_number_request = @NUMBER_MAXIMUM_OF_REQUEST@ +limit_number_request = 100 # Interval to check the factory -monitor_interval = @MONITOR_INTERVAL@ -timeout_response = @TIMEOUT_RESPONSE@ -enable_memory_monitor = @ENABLE_MEMORY_MONITOR@ +monitor_interval = 10 +timeout_response = 180 +enable_memory_monitor = True # Set the limit in MB # e.g 1000 = 1 GB, 100 = 100 MB -limit_memory_used = @MAXIMUM_USE_BY_OPENOFFICE@ +limit_memory_used = 3000 # ## OOFactory Settings # # The pool consist of several OpenOffice.org instances -application_hostname = @APPLICATION_HOSTNAME@ +application_hostname = localhost # OpenOffice Port -openoffice_port = @OPENOFFICE_PORT@ +openoffice_port = 4062 # ## Xvfb Settings # # Default port to xvfb -virtual_display_port = @XVFB_PORT@ +virtual_display_port = 6097 # ID of the virtual display where OOo instances are launched -virtual_display_id = @XVFB_DISPLAY_ID@ -virtual_screen = @XVFB_SCREEN_NUMBER@ +virtual_display_id = 97 +virtual_screen = 0 [server:main] use = egg:PasteScript#wsgiutils -host = @SERVER_HOST@ -port = @SERVER_PORT@ +host = 0.0.0.0 +port = 8011 diff --git a/cloudooo/samples/cloudooo.conf.in b/cloudooo/samples/cloudooo.conf.in new file mode 100644 index 0000000000000000000000000000000000000000..19ab2b9ce6daa9e0be99a150c188fc8007fa4fdd --- /dev/null +++ b/cloudooo/samples/cloudooo.conf.in @@ -0,0 +1,21 @@ +[app:main] +use = egg:cloudooo +debug_mode = @DEBUG_MODE@ +working_path = @WORKING_PATH@ +uno_path = @UNO_PATH@ +office_binary_path = @OFFICE_BINARY_PATH@ +limit_number_request = @NUMBER_MAXIMUM_OF_REQUEST@ +monitor_interval = @MONITOR_INTERVAL@ +timeout_response = @TIMEOUT_RESPONSE@ +enable_memory_monitor = @ENABLE_MEMORY_MONITOR@ +limit_memory_used = @MAXIMUM_USE_BY_OPENOFFICE@ +application_hostname = @APPLICATION_HOSTNAME@ +openoffice_port = @OPENOFFICE_PORT@ +virtual_display_port = @XVFB_PORT@ +virtual_display_id = @XVFB_DISPLAY_ID@ +virtual_screen = @XVFB_SCREEN_NUMBER@ + +[server:main] +use = egg:PasteScript#wsgiutils +host = @SERVER_HOST@ +port = @SERVER_PORT@ diff --git a/cloudooo/samples/sample.conf b/cloudooo/samples/sample.conf new file mode 100644 index 0000000000000000000000000000000000000000..f57d70a625704242c3133d5002c81ebc771d3bcf --- /dev/null +++ b/cloudooo/samples/sample.conf @@ -0,0 +1,47 @@ +[app:main] +use = egg:cloudooo +# +## System config +# +debug_mode = True +# Folder where pid files, lock files and virtual frame buffer mappings +# are stored. In this folder is necessary create a folder tmp, because this +# folder is used to create all temporary documents. +working_path = /hd/cloudooo/run +# Folder where OpenOffice Uno interpreter is installed +uno_path = /opt/openoffice.org3/basis-link/program +# Folder where OpenOffice Binarie is installed +office_binary_path = /opt/openoffice.org3/program +# +## Monitor Settings +# +# Limit to use the Openoffice Instance. if pass of the limit, the instance is +# stopped and another is started. +limit_number_request = 100 +# Interval to check the factory +monitor_interval = 10 +timeout_response = 180 +enable_memory_monitor = True +# Set the limit in MB +# e.g 1000 = 1 GB, 100 = 100 MB +limit_memory_used = 3000 +# +## OOFactory Settings +# +# The pool consist of several OpenOffice.org instances +application_hostname = localhost +# OpenOffice Port +openoffice_port = 4062 +# +## Xvfb Settings +# +# Default port to xvfb +virtual_display_port = 6097 +# ID of the virtual display where OOo instances are launched +virtual_display_id = 97 +virtual_screen = 0 + +[server:main] +use = egg:PasteScript#wsgiutils +host = 0.0.0.0 +port = 8011