Salome HOME
PR: ROOT_DIR to virtual link = APPLI directory
[modules/kernel.git] / bin / appliskel / README
1 =======================================
2 Set of scripts for a SALOME application
3 =======================================
4 *html version of this document is produced with docutils*::
5
6   rest2html < doc.txt > doc.html
7
8 This document corresponds to SALOME2 3.1. (alpha version)
9
10 +-------------------------------------------+
11 | **WORK in PROGRESS, INCOMPLETE DOCUMENT** |
12 +-------------------------------------------+
13
14 SALOME Application concept
15 --------------------------
16
17 See SALOME_Application_ to define your own configuration of SALOME and run it
18 on one or several computers. This is the recommended way of configuration.
19
20 .. _SALOME_Application: ../../doc/SALOME_Application.html
21
22
23 User run scripts
24 ----------------
25
26 The SALOME user can use the following scripts:
27
28 runAppli
29    Launches a SALOME Session
30    (similar to ${KERNEL_ROOT_DIR}/bin/salome/runSalome but with a different
31    name to avoid confusions).
32
33 runSession
34    Launches a shell script in the SALOME application environment, with access
35    to the current SALOME session (naming service), if any.
36    Without arguments, the script is interactive. With arguments, the script
37    executes the command in the SALOME application environment.
38
39 runConsole
40    Gives a python console connected to the current SALOME Session.
41    It is also possible to use runSession, then python.
42
43 runTests
44    Similar to runSession, used for unit testing. runTests defines a new 
45    configuration for naming service (new port number) to avoid interferences
46    with a running SALOME session. runSession tries to use an already existing
47    naming service definition from a running session (hostname & port number).
48
49 killCurrentPort
50    Kills the last SALOME session corresponding to this application, and 
51    intially launched from this computer.
52    Cleans associated config files.
53
54 SALOME internal run scripts
55 ---------------------------
56
57 envd
58    Sets SALOME application environment, envd is sourced by other scripts.
59
60 setAppliPath.sh
61    Used by other scripts to define the Application Path.
62
63 searchFreePort.sh
64    Used by other scripts to find a free port for naming service.
65
66 For remote calls, SALOME uses one script.
67
68 runRemote.sh
69    This script is mainly used to launch containers. The first 2 arguments
70    define the hostname and port userd for naming service, the remaining
71    arguments define the command to execute.
72
73
74 The following files must be adapted to your environment and SALOME Application
75 ------------------------------------------------------------------------------
76
77 - CatalogResources.xml
78 - SalomeApp.xml
79 - env.d/atFirst.sh
80 - env.d/envProducts.sh
81 - env.d/envSalome.sh
82
83 CatalogRessources.xml
84    This files describes all the computer the application can use. The given
85    example is minimal and suppose ${APPLI} is the same relative path
86    to ${HOME}, on all the computers. A different directory can be set on a
87    particular computer with a line::
88
89        appliPath="my/specific/path/on/this/computer"
90
91 SalomeApp.xml
92    This file is similar to the default given
93    in ${GUI_ROOT_DIR}/share/salome/resources/gui
94
95
96 Proposal for env.d scripts
97 ~~~~~~~~~~~~~~~~~~~~~~~~~~
98 Each user **must define** his own configuration for these scripts, following
99 the above rules. **The following is only an example not working as it is**.
100
101 atFirst.sh
102     Sets the computer configuration not directly related to SALOME,
103     like useful tools, default PATH.
104
105 envProducts.sh
106     Sets the SALOME prerequisites.
107
108 envSALOME.sh
109     Sets all the MODULE_ROOT_DIR that can be used in the SALOME application.
110
111     SalomeAppConfig is also defined by::
112
113       export SalomeAppConfig=${HOME}/${APPLI}
114
115     where SalomeAppConfig designates the directory containing SalomeApp.xml. 
116     Note that ${APPLI} is already defined by the calling scripts when 
117     env.d/envSalome.sh is sourced.