quinten1333 / bachalor-thesis

All the code that I wrote for my Bachelor thesis in the thesis branch. A fully functioning application which has been used to host thesis fair events at the University of Amsterdam in the master branch.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Results from the thesis

The results from the thesis can not be uploaded to Github because of their file size. Instead they are zipped and uploaded to: https://drive.google.com/file/d/1r-DbMiRJAOAF3xjA-t0pOvYENAZvQW_Y/view?usp=sharing

Docker compose

The docker-files in the different service folders should be executed from the git root.

The following environment variables should be used within the docker-compose files:

  • NODE_ENV -> Set as NODE_ENV during building
  • NODE_CMD -> Command to execute to start the container, either start for development with automatic restarting or production for production.

Shared libraries

Are in the libraries folder. The folder name should match their package name on npm so that during build the code can be rewritten to make regex pattern (\.\./)*libraries/amqpmessaging/index.js -> @amicopo/amqpmessaging/index.js

Shared databases

In production each service should have their own database. In the docker-compose.yml files every service has their own mongodb service. However, because these all have the same name only one will be created and all services will communicate with the same mongodb database.

Cluster urls

Installation

Installing the OS

  1. On the host pc run cd server/install/ && python Arch-installer/serve.py config.sh
  2. On the server, boot into the archlinux live iso
  3. Download the installer by doing curl <host pc ip>:8000/dl.sh | sh
  4. Start the installer: ./install.sh
  5. Follow the install instructions

Installing kubernetes

Execute init.sh on the server. This can be done by doing:

  1. scp server/install/init.sh <server ip>:~/init.sh
  2. ssh <server ip>
    • chmod +x init.sh
    • ./init.sh
  3. Download kube config to local machine: scp <server ip>:~/.kube/config ~/.kube/config

Initializing kubernetes

  1. Point the ssh command in server/initKubernetes/build.sh(line 12) to your server.
  2. Run make init

Running the ThesisFair software

To deploy run make up.

To remove the deployment run make down

To seed the database for stress testing run make seed. Config for this can be found in kubernetes/dbInit.yaml.

About

All the code that I wrote for my Bachelor thesis in the thesis branch. A fully functioning application which has been used to host thesis fair events at the University of Amsterdam in the master branch.

License:GNU General Public License v3.0


Languages

Language:JavaScript 84.3%Language:Python 7.5%Language:Shell 4.3%Language:Dockerfile 2.1%Language:Makefile 1.8%