changeset 213:f40f7d15e6bb

updated configuration file section
author amazy
date Fri, 22 Feb 2019 10:30:49 +0100
parents 7ff807cc5ade
children f8c55b461d16
files Sphinx/buildWithDocker.sh Sphinx/source/users/configuration.rst
diffstat 2 files changed, 36 insertions(+), 16 deletions(-) [+]
line wrap: on
line diff
--- a/Sphinx/buildWithDocker.sh	Fri Feb 22 10:02:23 2019 +0100
+++ b/Sphinx/buildWithDocker.sh	Fri Feb 22 10:30:49 2019 +0100
@@ -1,4 +1,2 @@
 docker build -t orthanc-book-builder .
-docker run --rm -v $(pwd):/app orthanc-book-builder
-
-docker rmi orthanc-book-builder  # since we rebuild it anyway, no need to keep it -> don't accumulate <none> images
\ No newline at end of file
+docker run --rm -v $(pwd):/app orthanc-book-builder
\ No newline at end of file
--- a/Sphinx/source/users/configuration.rst	Fri Feb 22 10:02:23 2019 +0100
+++ b/Sphinx/source/users/configuration.rst	Fri Feb 22 10:30:49 2019 +0100
@@ -4,20 +4,16 @@
 Configuration of Orthanc
 ========================
 
-Configuring Orthanc simply consists in copying and adapting the
-`default configuration file
+Configuring Orthanc simply consists in providing a configuration file.
+Orthanc has numerous configuration that are documented in the `default 
+configuration file
 <https://bitbucket.org/sjodogne/orthanc/raw/Orthanc-1.5.4/Resources/Configuration.json>`_. This
 file is in the `JSON <https://en.wikipedia.org/wiki/JSON>`_ file
-format. You can generate a sample configuration file with the
+format. You can generate this file file with the
 following call::
 
     $ Orthanc --config=Configuration.json
 
-Then, start Orthanc by giving it the path to the modified
-Configuration.json path as a command-line argument::
-
-    $ Orthanc ./Configuration.json
-
 The default configuration file would:
 
 * Create a DICOM server with the DICOM AET (Application Entity Title)
@@ -25,18 +21,44 @@
 * Create a HTTP server for the REST API that listens on the port 8042.
 * Store the Orthanc database in a folder called ``OrthancStorage``.
 
+However, we recommend that you start from an empty configuration file
+and only specify the options for which you don't wan't to use
+the default value.  In exemple, a simple configuration file would be::
+
+    {
+        "Name": "My archive",
+        "HttpPort": 80,
+        "DicomAet": "ARCHIVE",
+        "DicomPort": 104
+    }
+
+It's also a very good practice to split your configuration files per topic.
+In exemple, have a ``dicom.json`` for everything that is related to DICOM,
+a ``http.json`` for all HTTP related configurations, one file per plugin...  
+This is how the configuration files are provided with the Windows Installer.
+
+Once your configuration file is ready, start Orthanc by giving it the path to the 
+configuration file path as a command-line argument.  If you use multiple configuration
+files, you may provide the path to the folder containing all configuration files 
+(all ``.json`` files will be loaded)::
+
+    $ Orthanc ./Configuration.json
+    $ Orthanc ./config/
+
+
 *Remark:* When specifying paths under Microsoft Windows, backslashes
 (i.e. ``\``) should be either escaped by doubling them (as in ``\\``),
 or replaced by forward slashes (as in ``/``).
+*Remark:* When installing Orthanc with the Windows Installer, you won't be
+able to edit your files unless you start your editor with ``Run as administrator``.
+We recommend to edit your configuration file with an editor such as `Notepad++ <https://notepad-plus-plus.org/>`_.  
+It shall warn you that this file can be edited only by an admin, and will suggest you 
+to restart Notepad++ as an admin such that you'll be able to save it.
 
+ 
 To obtain more diagnostic, you can use the ``--verbose`` or the
 ``--trace`` options::
 
     $ Orthanc ./Configuration.json --verbose
     $ Orthanc ./Configuration.json --trace
 
-Starting with Orthanc 0.9.1, you can also start Orthanc with the path
-to a directory. In such a case, Orthanc will load all the files with a
-``.json`` extension in this directory, and merge them to construct the
-configuration file. This allows to split the global configuration into
-several files.