**WARNING** : Deploying `jami-web` with Docker is much easier than using the `tar.gz` files. Keep in mind that the data will be managed through Docker volumes and will remain persistent unless manually deleted. Proceed with caution.
Ensure that you are in the root of the working directory before proceeding.
```console
docker compose up --build -d
```
The application is now running on port 8080 of your local machine. To set up the reverse proxy, please refer to the Nginx configuration section below.
## Deploy from tar.gz
### Depedencies
**WARNING:** Currently, as the `tar.gz` files are built using an `ubuntu:22.04` container, the `jamid.node` binary can only be executed on this operating system due to dependency issues. This limitation may be resolved in the future. However, for now, if you wish to deploy Jami, please ensure it is installed on an `ubuntu:22.04` machine.
If you still want to deploy Jami on your current OS, please see deployment using Docker containers.
To ensure the application runs correctly, please install the required dependencies.
You can verify the version installed using the following command
`node -v`
### User to manage the app
Add the user
`sudo useradd -m jamid`
Give the user the right to create files, modify and delete files in /opt
`sudo chgrp -R jamid /opt`
### Systemd service
Creating a systemd service is a good practice as it allows the application to be managed using systemd commands and ensures that it automatically starts on reboot. This simplifies service management and improves reliability.
`sudo touch /etc/systemd/system/jami-web.service`
```
sudo tee /etc/systemd/system/jami-web.service > /dev/null << EOF
Remember, this is just an example, and other configurations can work perfectly as long as the desired port (80 or 443) is properly redirected to the application's running port (8080). In this example, we use Nginx, but the same setup could be achieved with Apache2 or any reverse proxy of your choice.
The application can be executed using a GitLab/GitHub runner or through a continuous deployment configuration. This setup will connect to the server, update the necessary files, and restart the server. Ensure that the `jamid` user has a defined home directory; otherwise, the application will be unable to store data.
> Running the app yourself without a continuous deployment configuration is not recommended
Alternatively, for a quick installation, you can run the `./install.sh` script, which will handle all the required steps automatically (except for the Nginx configuration).