Last modified by Aurelie Bertrand on 2025/12/19 08:51

Show last authors
1 {{ddtoc/}}
2
3 ----
4
5 (% class="wikigeneratedid" %)
6 The export of certain Flows (graphics), such as D3, Gantt or Open Street Map, requires the use of nodejs.
7
8 (% class="wikigeneratedid" %)
9 To run nodejs, follow the instructions below.
10
11 = Install Chromium =
12
13 The nodejs export requires the Chromium browser to be installed.
14
15 For installation on Ubuntu 22.04, use the following commands:
16
17 {{code}}
18 sudo wget "http://keyserver.ubuntu.com/pks/lookup?op=get&search=0x869689FE09306074" -O /etc/apt/trusted.gpg.d/phd-chromium.asc
19 echo "deb [signed-by=/etc/apt/trusted.gpg.d/phd-chromium.asc] https://freeshell.de/phd/chromium/$(lsb_release -sc) /" | sudo tee /etc/apt/sources.list.d/phd-chromium.list
20 sudo apt-get update
21 sudo snap remove chromium
22 sudo apt-get -y purge chromium-browser
23 sudo apt-get -y autoremove
24 sudo apt-get -y install chromium
25 {{/code}}
26
27 = Activate the nodejs export server =
28
29 1. Edit the **system.xml **file in the **<digdash.appdata>/Enterprise Server/ddenterpriseapi/config** folder.
30 1. Add the line:
31
32 {{code language="batch" cssClass="notranslate"}}
33 <Property key="NODEJS_EXPORT" value="true"></Property>
34 {{/code}}
35
36 (% start="3" %)
37 1. Restart the tomcat server.
38
39 = Set up the nodejs server =
40
41 If the tomcat ip address and port are different from the default values (localhost:8080), edit the **digdash.properties** file **.**
42 Uncomment or add the following line:
43
44 {{code language="properties" cssClass="notranslate"}}
45 ddenterpriseapi.SERVERURL=http://localhost:8080
46 {{/code}}
47
48 (% class="box infomessage" %)
49 (((
50 💡To uncomment a parameter in the digdash.properties file, delete the # character at the beginning of the line.
51 )))
52
53 = Export via NodeJS multi-domain =
54
55 For a multi-domain installation on the same machine, exports using NodeJS are not functional except for the default domain ("defautHost" in tomcat's server.xml).
56
57 For a "classic" installation with 3 domains such as "default, rct, dev", add the following lines to the "digdash.properties" file:
58
59 (% class="box infomessage" %)
60 (((
61 ℹ For the "NODEJSURL" parameter, the ports must be distinct per domain on the same machine (3000 then 3001 and 3002 in the example below). They do not have to be continuous (but they do have to be free, of course).
62 )))
63
64 {{code language="properties"}}
65 ddenterpriseapi.DDAPIFORNODEJSURL=http://localhost:8080
66 ddenterpriseapi_rct.DDAPIFORNODEJSURL=http://localhost-rct:8080
67 ddenterpriseapi_dev.DDAPIFORNODEJSURL=http://localhost-dev:8080
68
69 ddenterpriseapi.NODEJSURL=http://localhost:3000
70 ddenterpriseapi_rct.NODEJSURL=http://localhost-rct:3001
71 ddenterpriseapi_dev.NODEJSURL=http://localhost-dev:3002
72 {{/code}}