Deploy Your Application
How you will deploy your ChatAlly application depends very much on the modules that you use, specifically the servers/channels that you use to connect to your users’ clients.
In this guide, we will explain an exemplary deployment of a WhatsApp Cloud chat application.
Create the application
-
Follow the Getting Started guide to create an initial application in the directory
app
-
In the
app
directory, install additional modules -
Add WhatsApp to the application (instead of the ConsoleServer)
- using
webhooks.path
would allow us, to run multiple servers for webhooks within one container, e.g. if you want to add a Signal server later - changing
media.dbPath
from the default to a subdirectory, will allow us to map a docker volume to that location and thus persist the database
- using
Create a Docker container
-
Create the
Dockerfile
The WhatsApp Cloud server will run a webhooks endpoint at port 3000. If you reconfigure this, you will need to expose a different port here.
-
Build the image
-
Run the container
We deploy our containers with docker swarm behind a Traefik proxy, but you are free to do however you prefer
- We map a local
data
directory to/app/data
, which we have configured as target for our media id database - Adapt the
Host
rule according to your domain.
- We map a local