From: Jérôme Benoit Date: Wed, 15 Apr 2020 17:41:11 +0000 (+0200) Subject: Put the simulator configuration file in src/assets. X-Git-Tag: v1.0.1-0~365 X-Git-Url: https://git.piment-noir.org/?a=commitdiff_plain;h=4d127f7fc6712dd32fb8ca3da47989e0c911ffe9;p=e-mobility-charging-stations-simulator.git Put the simulator configuration file in src/assets. Signed-off-by: Jérôme Benoit --- diff --git a/.gitignore b/.gitignore index ea6e6ea4..0e351bb9 100644 --- a/.gitignore +++ b/.gitignore @@ -1,5 +1,5 @@ # config -src/config.json +src/assets/config.json manifest.yml # Logs @@ -64,4 +64,4 @@ build/config.gypi *~ # Clinic -*.clinic-* \ No newline at end of file +*.clinic-* diff --git a/README.md b/README.md index 2a77dc14..bf387f9f 100644 --- a/README.md +++ b/README.md @@ -6,7 +6,7 @@ Simple node program to simulate a set of charging stations based on OCPP 1.6 pro To run the program start: `npm start`. -All the parameters and control of the program are within the config.json file. +All the parameters and control of the program are within the src/assets/config.json file. A configuration template file is available at src/assets/config-template.json. ## License diff --git a/docker/Dockerfile b/docker/Dockerfile index d681e295..32ef353d 100644 --- a/docker/Dockerfile +++ b/docker/Dockerfile @@ -15,7 +15,7 @@ COPY --from=builder /usr/builder/node_modules ./node_modules COPY NOTICE LICENSE ./ COPY src ./src COPY *.json ./ -COPY docker/config.json ./src/config.json +COPY docker/config.json ./src/assets/config.json COPY docker/autoconfig.sh /autoconfig.sh RUN chmod +x /autoconfig.sh diff --git a/src/config-template.json b/src/assets/config-template.json similarity index 100% rename from src/config-template.json rename to src/assets/config-template.json diff --git a/src/utils/Configuration.js b/src/utils/Configuration.js index 4ed9cb7d..7fdfbe2d 100644 --- a/src/utils/Configuration.js +++ b/src/utils/Configuration.js @@ -1,4 +1,4 @@ -const config = require('../config.json'); +const config = require('../assets/config.json'); class Configuration { // Read the config file