From eda3af6c4924dc5b5f5159c893e0a9e7aebbcbc8 Mon Sep 17 00:00:00 2001 From: Mike Mwanje Date: Wed, 2 Nov 2022 17:33:14 +0300 Subject: [PATCH 1/4] Add a .env.sample for the Netmanager This was originally implemented by @rohitkori and polished by @123MwanjeMike Co-Authored-By: Rohit Kumar Kori <99089826+rohitkori@users.noreply.github.com> --- netmanager/.env.sample | 16 ++++++++++++++++ netmanager/README.md | 14 +++++++------- 2 files changed, 23 insertions(+), 7 deletions(-) create mode 100644 netmanager/.env.sample diff --git a/netmanager/.env.sample b/netmanager/.env.sample new file mode 100644 index 0000000000..bfe7cc2950 --- /dev/null +++ b/netmanager/.env.sample @@ -0,0 +1,16 @@ +REACT_APP_BASE_URL=https://staging-platform.airqo.net/api/v1/ +REACT_APP_BASE_ANALYTICS_URL= +REACT_APP_BASE_AUTH_SERVICE_URL= +REACT_APP_BASE_DATA_MANAGEMENT_URL= +REACT_APP_BASE_DEVICE_MONITORING_URL= +REACT_APP_BASE_DEVICE_REGISTRY_URL= +REACT_APP_BASE_LOCATE_URL= +REACT_APP_BASE_LOCATION_REGISTRY_URL= +REACT_APP_BASE_PREDICT_URL= +REACT_APP_MAX_CONFIDENCE_INTERVAL= +REACT_APP_CLOUDINARY_NAME=abcdef +REACT_APP_CLOUDINARY_PRESET=abcdef +REACT_APP_MAPBOX_TOKEN=pk.ey123abc +REACT_APP_JIRA_KEY=abcdef +NODE_PATH=src/ +PORT=5000 \ No newline at end of file diff --git a/netmanager/README.md b/netmanager/README.md index 7e8be0c456..826ad97380 100644 --- a/netmanager/README.md +++ b/netmanager/README.md @@ -1,30 +1,30 @@ # Netmanager Application + This application is used for monitoring, device registration, location registration. Can be accessed here: https://staging-platform.airqo.net/ and https://platform.airqo.net/ ## Local Setup + npm is our package manager of choice here. Check out setup instructions [here](https://nodejs.org/dist/) if you don't have it installed already.

**Note: This project is currently using node version 14.** To run the app, enter the project directory
-**a) Add the `.env` file to the root folder.** You can find it [here](https://drive.google.com/drive/folders/1RYuukiTYgVxMBlSa4K8miLYiM_W4T86o)
+**a) Add the `.env` file** +You need to fill actual values to the environment variables while creating the respective `.env` file from [.env.sample](./.env.sample) file **b) Install all the needed dependencies** - - + npm install + **c) Run in Development mode** - npm run dev **d) Run in Staging mode** - npm run stage **e) Run in Production mode** - npm run prod -Now, the application should be running on `http://localhost:5000`. \ No newline at end of file +Now, the application should be running on `http://localhost:5000`. From e57606c677afe5c4e97a8e87afedebee4e176ef1 Mon Sep 17 00:00:00 2001 From: Mike Mwanje Date: Wed, 2 Nov 2022 17:51:13 +0300 Subject: [PATCH 2/4] add line break --- netmanager/README.md | 1 + 1 file changed, 1 insertion(+) diff --git a/netmanager/README.md b/netmanager/README.md index 826ad97380..ba438ee5bf 100644 --- a/netmanager/README.md +++ b/netmanager/README.md @@ -9,6 +9,7 @@ npm is our package manager of choice here. Check out setup instructions [here](h To run the app, enter the project directory
**a) Add the `.env` file** + You need to fill actual values to the environment variables while creating the respective `.env` file from [.env.sample](./.env.sample) file **b) Install all the needed dependencies** From 5207a72a7cdae46e518d7a31932128ccd09d86c4 Mon Sep 17 00:00:00 2001 From: Mike Mwanje Date: Wed, 2 Nov 2022 17:52:15 +0300 Subject: [PATCH 3/4] add line break --- netmanager/README.md | 1 + 1 file changed, 1 insertion(+) diff --git a/netmanager/README.md b/netmanager/README.md index ba438ee5bf..d3e5fb30f2 100644 --- a/netmanager/README.md +++ b/netmanager/README.md @@ -8,6 +8,7 @@ npm is our package manager of choice here. Check out setup instructions [here](h **Note: This project is currently using node version 14.** To run the app, enter the project directory
+ **a) Add the `.env` file** You need to fill actual values to the environment variables while creating the respective `.env` file from [.env.sample](./.env.sample) file From 57f6392f62a414af312ea90a493338102a63dbd9 Mon Sep 17 00:00:00 2001 From: Mike Mwanje Date: Wed, 2 Nov 2022 17:54:52 +0300 Subject: [PATCH 4/4] Empty values not required for app to run --- netmanager/README.md | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/netmanager/README.md b/netmanager/README.md index d3e5fb30f2..8092fff496 100644 --- a/netmanager/README.md +++ b/netmanager/README.md @@ -11,7 +11,8 @@ To run the app, enter the project directory
**a) Add the `.env` file** -You need to fill actual values to the environment variables while creating the respective `.env` file from [.env.sample](./.env.sample) file +You need to fill actual values to the environment variables while creating the respective `.env` file from [.env.sample](./.env.sample) file. +Note that the variables with no (dummy)values are not required to get the app up and running. **b) Install all the needed dependencies**