diff --git a/Dev.md b/Dev.md index 464378af..e4bf7d91 100644 --- a/Dev.md +++ b/Dev.md @@ -7,22 +7,42 @@ ### Env Variables These are the env variables that need to be set-up: -- MONGO_READ: The connection string -- MONGO_DATABASE: Which database to use -- GITHUB_TOKEN: The Github token -- LOG_PATH: The path for the log files to be saved in -- DATA_PATH: The path for the data files to be saved in +- MONGO_READ: The connection string. Can be found in Keepass +- MONGO_DATABASE: Which database to use. production or testingNew +- GITHUB_TOKEN: The Github token. Can be found in Keepass +- LOG_PATH: The path for the log files to be saved in. Somewhere on your system. +- DATA_PATH: The path for the data files to be saved in. Somewhere on your system. ### Run Backend > - From root cd into */oss-api*
-> - Run npm i to install all the necessary packages -> - Finally you can start the dec server with **npm run start:dev** +> - Run **npm i** to install all the necessary packages +> - Finally you can start the dev server with **npm run start:dev** ## Frontend **Pre-requirements:** AngularJS, npm, finished backend setup > - From root cd into */frontend*
-> - Run npm i to install all the necessary packages
-> - Finally you can start the dev server with **npm run start** \ No newline at end of file +> - Run **npm i** to install all the necessary packages
+> - Finally you can start the dev server with **npm run start** + + +# Update Institutions + +Once someone has updated the github_repos.json file and the pull request was merged, the new or updated insitution must be added to the database. + +This can be done in 4 easy steps: + +1. Pull Repository +2. Enter the connection string, which can be found in Keepass, into the URI field of MongoCompass. + +![MongoCompass Connection string](/assets/images/MongoConnection.png) + +3. Choose the **production** DB and then todoInstitution collection. + +![Mongo choose DB](/assets/images/MongoDB.png) + +4. Press **Add Data -> Import file** and choose github_repos.json. Keep in mind that *Stop on errors* needs to be unchecked. Then just click *Import*. + +![Add new Data to DB](/assets/images/AddData.png) \ No newline at end of file diff --git a/README.md b/README.md index 144b04fd..5da69354 100644 --- a/README.md +++ b/README.md @@ -41,15 +41,4 @@ The crawler will just update the data, starting with the oldest timestamp. ## Database Stucture -![System Diagram](/assets/images/DBStructure.png) - -## Update Institutions - -Once someone has updated the github_repos.json file and the pull request was merged, the new or updated insitution must be added to the database. - -This can be done in 4 easy steps: - -1. Pull Repository -2. Connect to DB with MongoDB Compass. The Credentials can be found in Keepass -3. Choose the **production** DB and then todoInstitution collection. -4. Press **Add Data -> Import file** and choose github_repos.json. Keep in mind that *Stop on errors* needs to be unchecked. Then just click *Import*. \ No newline at end of file +![System Diagram](/assets/images/DBStructure.png) \ No newline at end of file diff --git a/assets/images/AddData.png b/assets/images/AddData.png new file mode 100644 index 00000000..ccccdfbb Binary files /dev/null and b/assets/images/AddData.png differ diff --git a/assets/images/MongoConnection.png b/assets/images/MongoConnection.png new file mode 100644 index 00000000..5e3eb24c Binary files /dev/null and b/assets/images/MongoConnection.png differ diff --git a/assets/images/MongoDB.png b/assets/images/MongoDB.png new file mode 100644 index 00000000..484b600d Binary files /dev/null and b/assets/images/MongoDB.png differ