Skip to content

Prepare Install Environment

Before installing the application, it is essential to prepare the installation environment. Follow the steps below to set up the necessary directories, files, and permissions.

General

No matter how you want to deploy the Application you need to do the following steps.

Application directory

Create a dedicated directory for the application installation. This directory will house all the necessary files and configurations.

mkdir -p /opt/rooms
cd /opt/rooms

Set Frontend Config

Copy the config.json from the remote repository to you local installation directory. This specifies the Backend URL that the Frontend will use so set it according to your deployment needs.

cp <path_to_remote_repo>/deployment/config.json
vi config.json

Generate JWT Keys

The application requires JWT keys for secure authentication. Generate a pair of EC keys using OpenSSL. Run the following commands to create the private and public keys:

1
2
3
mkdir -p keys
openssl ecparam -name prime256v1 -genkey -noout -out keys/jwt_private_key.ec.key
openssl ec -in keys/jwt_private_key.ec.key -pubout -out keys/jwt_public_key.ec.key

Local Deployment

If you only want a minimal working instance of the system, then follow these steps.

Setup Environment Variables

Copy the local template file from the remote repository to your local installation directory. This is a minimal version for easy configuration in local deployment. Fill in the required environment variables in the .env file according to your deployment needs.

cp <path_to_remote_repo>/deployment/.env.local.template .env
vi .env

Compose

If you want to run the application locally you dont need the fully featured compose.yml with all the extra services like dozzle. In this case it might be enought to run a barebone version with only the core services like the frontend and backend. For this scenario we offer the compose.local.yml. Just copy it instead of the full compose.yml like this:

cp <path_to_remote_repo>/deployment/compose.local.yml compose.yml

Since this compose does not include traefik for rerouting you can expect the services at http://localhost:<port> where the port is specified in the compose file.

Server Deployment

If you want the full setup with everything you could ask for then follow these steps.

Setup Environment Variables

Copy the environment template file from the remote repository to your local installation directory. This file serves as a template for your environment variables. Rename the copied file to .env to use it as your environment configuration. Fill in the required environment variables in the .env file according to your deployment needs.

cp <path_to_remote_repo>/deployment/.env.template .env
vi .env

Lets Encrypt Directory

Create a directory for Let’s Encrypt to store SSL certificates. This directory will be used by the application to manage SSL certificates.

1
2
3
mkdir -p letsencrypt
touch letsencrypt/acme.json
chmod 600 letsencrypt/acme.json

mkdocs Sync Settings

To keep the documentation up to date, set up a script to synchronize the mkdocs content. Copy the mkdocs_sync.sh script from the remote repository and make it executable. Then, run the script to perform the initial synchronization.

1
2
3
cp <path_to_remote_repo>/deployment/mkdocs_sync.sh mkdocs_sync.sh
chmod +x mkdocs_sync.sh
./mkdocs_sync.sh

Compose

Download the docker-compose.yml file from the remote repository to your installation directory. This file contains the necessary configurations for deploying the application using Docker Compose.

cp <path_to_remote_repo>/deployment/compose.yml compose.yml