diff --git a/README.md b/README.md index a95366a31789e132c3d7a425dade1985abc718f2..010cac1f60e602b839111488808c3f5bc5aae2ad 100644 --- a/README.md +++ b/README.md @@ -37,54 +37,6 @@ This is the user interface of the app, created using react, this app should visu ## Install instructions -Instructions on how to install this on a virtual machine over ssh: - -NEED TO HAVE A TLS CERTIFICATE AND KEY WITHIN FOLDER: -"*user_home_dir*/etc/letsencrypt/live/"domain_name"/fullchain.pem -"*user_home_dir*/etc/letsencrypt/live/"domain_name"/privkey.pem - -Before starting remember that certain changes will have to be done in order to use TLS, (such as changing the paths in the docker compose files and dockerfiles for TLS keys), and this guide will not take these things into account. - -1. Connect to the machine over ssh. -2. Install docker onto the machine -3. Pull the project repository, or move the files to the virtual machine some other way -4. run the command "sudo docker compose -f docker-compose.yaml up --build -d" -5. Set up the latest Chirpstack docker container, found [here](https://hub.docker.com/r/chirpstack/chirpstack/tags) - 1. After starting the container, set up a channel through ssh to a local computer, command: `ssh -D 8080 -C -N "username"@"ip_adress"`. replace "username" with the username and "ip_adress" with the ip adress. - 2. open firefox, go to setting, open proxy settings, set to manual proxy settings, SOCKS-server: 127.0.0.1, port 8080, socks v5. - 3. going to the search bar, type http://172.20.0.7:8080/ and login. Default password/username is admin - 4. create an API key and save it somewhere secure. - 5. Create a device profile with these parameters (unspecified is default) - 1. region EU868 - 2. MAC version: LoraWAN 1.0.2 - 3. ADR algorithm: LoRa & LR-FHSS ADR algorithm - 4. expected uplink: 60 sec - 5. regional parameters: A - 6. supports OTAA: true - 7. payload codec: javascript functions - 8. Codec functions: copy text in *CODEC.md* - 6. Copy the device profile id and save it somewhere - 7. create an application and save the application id - 8. click dashboard and save the tenant id -6. connect all chirpstack docker instances to the docker network created by our docker compose file -7. Create a MariaDB container, connect to it, and execute the SQL file found in our project repository (under backend/commands.sql) call the database "test" -8. Connect MariaDB docker instance to the same network as the previously stated network. -9. Create a folder in the root directory called "envars", and within there two folders called "egress" and "ingress". inside each of these create a folder called ".env". - 1. inside egress/.env add the following entries: - 1. DB_PASS="your_mariadb_pass" - 2. DB_PATH="docker_ip_adress_to_mariadb_instance" (hint use sudo docker network inspect "network name") - 3. WEB_URL=https://"your_domain_name or ip_adress" - 4. ADMIN_WEB_URL=https://"your_domain_name or ip_adress":9094 - 2. inside ingress/.env add the following entries - 1. API_KEY=Bearer "the_API key you created" - 2. DB_PASS="your mariadb password here" - 3. DB_PATH="the same path as the other .env file" - 4. CHIRP_URL=http://"internal ip adress of the chirpstack instance":8090 (hint use docker newtwork inspect again) - 5. DEVICE_PROFILE_ID="device profile id" - 6. APPLICATION_ID="application id" - 7. TENANT_ID="tenant id" - 8. WEB_URL=https://"your_domain_name or ip_adress" - 9. ADMIN_WEB_URL=https://"your_domain_name or ip_adress":9094 -10. Run command from step 4 again, or manually do `sudo docker restart "container id"`for each of the containers. +Refer to the bacheleor report for install instructions.