installation.rst 4.68 KB
Newer Older
1 2 3
.. _gcu_installation:

************
4
Installation
5
************
6

7 8
Requirements & Limitations
==========================
9

10
The XiVO Centralized User Management requires :
11

12 13 14
- A server with:

  - Debian 8
15
  - PostgreSQL >= 9.5 (see `Debian backports <https://backports.debian.org/Instructions/>`_ or `Postgresql Wiki <https://wiki.postgresql.org/wiki/Apt>`_ for installing instructions)
16
  - Docker > 1.12 and corresponding Docker-Compose. Since version 2018.04 XCU
Vojtech Sodoma's avatar
Vojtech Sodoma committed
17
    requires Docker-CE instead of Docker Engine.
18 19 20 21
  - git installed
  - sudo installed

- Some XiVOs to manage !
22

23
  - see the next section for limitations on managed XiVOs.
24

25 26
.. _gcu_installation_requirements_for_xivos:

27 28
XiVO(s) Requirements & Limitations
==================================
29 30 31

.. warning:: Please double-check these requirements to prevent unexpected behavior.

32
For each Xivo which will be added to XCU ensure:
33

34 35
1. Create an Incoming calls interval in the `from-exten` context with a did length equal to the internal number length for each interval managed by XCU.
2. SCCP devices are not supported an may trigger error in the Centralized User Management. You must remove them on your XiVO before using this application.
36
3. On any context, Users interval *Number range start* and *Number range end* from must be 1-6 six digits (no other characters are allowed).
37
4. If you are making circular inclusions of asterisk context the XCU can potentially load users for a while, you should be **very** careful with such deployment.
38

39
Centralized routing will require further configuration - see :ref:`xcu_configuration_of_centralized_routing`.
40

Stepan Kabele's avatar
Stepan Kabele committed
41 42
Installation by installer package
=================================
43

Stepan Kabele's avatar
Stepan Kabele committed
44
Install the *gcu-installer* package via *apt*:
45

46 47 48 49 50 51
#. Create the xivo sources list file :file:`/etc/apt/sources.list.d/xivo-dist.list` and add the following line
   (replace **VERSION** with the current version, e.g. *2017.11*)::

    deb http://mirror.xivo.solutions/archive/ xivo-VERSION-latest main

#. Add GPG key of XiVO repository::
Stepan Kabele's avatar
Stepan Kabele committed
52 53

    wget http://mirror.xivo.solutions/xivo_current.key -O - | apt-key add -
54

Stepan Kabele's avatar
Stepan Kabele committed
55 56 57 58
#. Update your source list and install the package::

    apt-get update
    apt-get install gcu-installer
59 60 61

The configuration files are located in ``/etc/docker``.

62
.. _xcu_configuration:
63 64 65 66

Configuration
=============

67
The XCU configuration files are installed by the installer package to the `/etc/docker/` directory.
68

69
Authentication
70
--------------
71 72 73 74

Authentication is configured in ``/etc/docker/interface-centralisee/application.conf``, section ``authentication``:

* in ``authentication.login`` you can change initial user credentials (default admin / superpass)
XivoBuilder's avatar
XivoBuilder committed
75
* in ``authentication.ldap`` you can add configuration to use authentication via LDAP
76 77


78
.. _xcu_interval_overlapping:
79 80 81 82 83

Interval overlapping
--------------------

A parameter called `allowIntervalOverlap` with default value `false` is available in
84 85
``/etc/docker/interface-centralisee/application.conf``. When set to `false`, the XCU does not allow use overlapping
intervals, when an interval is created or edited the XCU checks whether the interval overlaps with other intervals
86 87 88
on all XiVOs and if it does the action is rejected. This default setting helps you to preserve a coherent numbering plan.

If for some reason you need to allow interval overlapping, you just need to change the value in the configuration file
89
to `true` and restart the XCU. It can be useful when some existing XiVO servers with overlapping intervals were
90 91
imported or when you want to be able to migrate some user to another XiVO without changing its number.

92 93 94
Run the application
===================

95
Star XCU by following command:
Stepan Kabele's avatar
Stepan Kabele committed
96 97 98 99 100

.. code-block:: bash

	docker-compose -p icdu -f /etc/docker/compose/icdu.yml up -d

101
Alternatively, you can set a bash alias for conveniently run XCU:
102 103 104 105 106

.. code-block:: bash

	alias dcomp='docker-compose -p icdu -f /etc/docker/compose/icdu.yml'

Stepan Kabele's avatar
Stepan Kabele committed
107
In that case you can use simpler command :
108 109

.. code-block:: bash
110

111 112
	dcomp up -d

113
XCU should now be accessible through http://my-server-ip or http://my-server-ip:9001
114

115

Stepan Kabele's avatar
Stepan Kabele committed
116 117 118 119 120 121
Application logs
================

1. General application log is in ``/var/log/interface-centralisee/application.log`` with daily rotation, historic logs
   retained for 5 days.
2. User actions are logged to ``/var/log/interface-centralisee/user_actions.log`` with daily rotation, historic logs
122 123
   retained for 366 days.

124
By default ``user_actions.log`` contains only brief information about which authorize XCU user did what action.
125 126 127 128 129 130 131
To log with more detail (including data of create and update actions), change in
``/etc/docker/interface-centralisee/logback.xml`` line:

.. code-block:: xml

    <logger name="UserActions"  level="INFO">

Stepan Kabele's avatar
Stepan Kabele committed
132
into:
133 134 135 136

.. code-block:: xml

    <logger name="UserActions"  level="DEBUG">