annotate Sphinx/source/users/configuration.rst @ 568:090cc988c35e

Orthanc 1.8.2
author Sebastien Jodogne <s.jodogne@gmail.com>
date Fri, 18 Dec 2020 16:17:37 +0100
parents 4f3a6145ae34
children eaa6cdfa7ba6
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
0
901e8961f46e initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
1 .. _configuration:
901e8961f46e initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
2 .. highlight:: bash
901e8961f46e initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
3
901e8961f46e initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
4 Configuration of Orthanc
901e8961f46e initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
5 ========================
901e8961f46e initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
6
213
f40f7d15e6bb updated configuration file section
amazy
parents: 196
diff changeset
7 Configuring Orthanc simply consists in providing a configuration file.
361
84e3a2612c36 links to hg
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 336
diff changeset
8 Orthanc has numerous configuration that are documented in the `default
213
f40f7d15e6bb updated configuration file section
amazy
parents: 196
diff changeset
9 configuration file
568
090cc988c35e Orthanc 1.8.2
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 554
diff changeset
10 <https://hg.orthanc-server.com/orthanc/file/Orthanc-1.8.2/OrthancServer/Resources/Configuration.json>`_. This
0
901e8961f46e initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
11 file is in the `JSON <https://en.wikipedia.org/wiki/JSON>`_ file
361
84e3a2612c36 links to hg
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 336
diff changeset
12 format. You can generate this file file with the following call::
0
901e8961f46e initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
13
901e8961f46e initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
14 $ Orthanc --config=Configuration.json
901e8961f46e initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
15
901e8961f46e initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
16 The default configuration file would:
901e8961f46e initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
17
901e8961f46e initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
18 * Create a DICOM server with the DICOM AET (Application Entity Title)
901e8961f46e initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
19 ``ORTHANC`` that listens on the port 4242.
901e8961f46e initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
20 * Create a HTTP server for the REST API that listens on the port 8042.
901e8961f46e initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
21 * Store the Orthanc database in a folder called ``OrthancStorage``.
901e8961f46e initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
22
213
f40f7d15e6bb updated configuration file section
amazy
parents: 196
diff changeset
23 However, we recommend that you start from an empty configuration file
f40f7d15e6bb updated configuration file section
amazy
parents: 196
diff changeset
24 and only specify the options for which you don't wan't to use
214
amazy
parents: 213
diff changeset
25 the default value. In example, a simple configuration file would be::
213
f40f7d15e6bb updated configuration file section
amazy
parents: 196
diff changeset
26
f40f7d15e6bb updated configuration file section
amazy
parents: 196
diff changeset
27 {
f40f7d15e6bb updated configuration file section
amazy
parents: 196
diff changeset
28 "Name": "My archive",
f40f7d15e6bb updated configuration file section
amazy
parents: 196
diff changeset
29 "HttpPort": 80,
f40f7d15e6bb updated configuration file section
amazy
parents: 196
diff changeset
30 "DicomAet": "ARCHIVE",
f40f7d15e6bb updated configuration file section
amazy
parents: 196
diff changeset
31 "DicomPort": 104
f40f7d15e6bb updated configuration file section
amazy
parents: 196
diff changeset
32 }
f40f7d15e6bb updated configuration file section
amazy
parents: 196
diff changeset
33
f40f7d15e6bb updated configuration file section
amazy
parents: 196
diff changeset
34 It's also a very good practice to split your configuration files per topic.
214
amazy
parents: 213
diff changeset
35 In example, have a ``dicom.json`` for everything that is related to DICOM,
213
f40f7d15e6bb updated configuration file section
amazy
parents: 196
diff changeset
36 a ``http.json`` for all HTTP related configurations, one file per plugin...
f40f7d15e6bb updated configuration file section
amazy
parents: 196
diff changeset
37 This is how the configuration files are provided with the Windows Installer.
f40f7d15e6bb updated configuration file section
amazy
parents: 196
diff changeset
38
f40f7d15e6bb updated configuration file section
amazy
parents: 196
diff changeset
39 Once your configuration file is ready, start Orthanc by giving it the path to the
f40f7d15e6bb updated configuration file section
amazy
parents: 196
diff changeset
40 configuration file path as a command-line argument. If you use multiple configuration
f40f7d15e6bb updated configuration file section
amazy
parents: 196
diff changeset
41 files, you may provide the path to the folder containing all configuration files
f40f7d15e6bb updated configuration file section
amazy
parents: 196
diff changeset
42 (all ``.json`` files will be loaded)::
f40f7d15e6bb updated configuration file section
amazy
parents: 196
diff changeset
43
f40f7d15e6bb updated configuration file section
amazy
parents: 196
diff changeset
44 $ Orthanc ./Configuration.json
f40f7d15e6bb updated configuration file section
amazy
parents: 196
diff changeset
45 $ Orthanc ./config/
f40f7d15e6bb updated configuration file section
amazy
parents: 196
diff changeset
46
f40f7d15e6bb updated configuration file section
amazy
parents: 196
diff changeset
47
73
c742c8f9ffa3 encodings
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 72
diff changeset
48 *Remark:* When specifying paths under Microsoft Windows, backslashes
c742c8f9ffa3 encodings
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 72
diff changeset
49 (i.e. ``\``) should be either escaped by doubling them (as in ``\\``),
c742c8f9ffa3 encodings
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 72
diff changeset
50 or replaced by forward slashes (as in ``/``).
213
f40f7d15e6bb updated configuration file section
amazy
parents: 196
diff changeset
51 *Remark:* When installing Orthanc with the Windows Installer, you won't be
f40f7d15e6bb updated configuration file section
amazy
parents: 196
diff changeset
52 able to edit your files unless you start your editor with ``Run as administrator``.
f40f7d15e6bb updated configuration file section
amazy
parents: 196
diff changeset
53 We recommend to edit your configuration file with an editor such as `Notepad++ <https://notepad-plus-plus.org/>`_.
f40f7d15e6bb updated configuration file section
amazy
parents: 196
diff changeset
54 It shall warn you that this file can be edited only by an admin, and will suggest you
f40f7d15e6bb updated configuration file section
amazy
parents: 196
diff changeset
55 to restart Notepad++ as an admin such that you'll be able to save it.
73
c742c8f9ffa3 encodings
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 72
diff changeset
56
213
f40f7d15e6bb updated configuration file section
amazy
parents: 196
diff changeset
57
0
901e8961f46e initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
58 To obtain more diagnostic, you can use the ``--verbose`` or the
901e8961f46e initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
59 ``--trace`` options::
901e8961f46e initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
60
901e8961f46e initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
61 $ Orthanc ./Configuration.json --verbose
901e8961f46e initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
62 $ Orthanc ./Configuration.json --trace
901e8961f46e initial commit
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
63
541
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 528
diff changeset
64 To learn more about the Orthanc logs, :ref:`check out the dedicated
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 528
diff changeset
65 page <log>`.