notice
This is documentation for Rasa X Documentation v0.38.x, which is no longer actively maintained.
For up-to-date documentation, see the latest version (1.1.x).
Docker Compose Installation
In this installation method, Rasa X is deployed on a server as a set of Docker containers.
An install script is available for servers that meet the hardware and OS requirements. For other operating systems, you can install Rasa X via Docker Compose manually.
Requirements
note
Rasa X is intended to be deployed on a server and not to a personal/local machine. Deploying on a server is recommended because Rasa X is designed to stay up continuously, and not to be frequently stopped or restarted.
Hardware & OS Requirements
Here are the minimum and recommended hardware specs and OS requirements:
Install Script | Manual Installation | |
Operating System | Ubuntu 16.04 / 18.04 / 19.10 Debian 9 / 10 CentOS 7 / 8 RHEL 8 | a modern Linux or Windows distribution that can run Docker |
vCPUs | Minimum: 2 vCPUs Recommended: 2-6 vCPUs | |
RAM | Minimum: 4 GB RAM Recommended: 8 GB RAM | |
Disk Space | * Recommended: 100 GB disk space available |
Port Requirements
When creating the server, make sure the following ports of are open:
Port | Service | Description |
---|---|---|
22 | SSH | SSH access. |
80 | HTTP | Web application access. |
443 | HTTPS | Web application over HTTPS access (optional) |
Supported Browsers
The web interface aims to support browsers that meet the following criteria:
0.2% market share
not Internet Explorer
not Opera Mini
Docker Compose Install Script
Watch the Rasa Masterclass video below to follow along with the install script instructions:
If you have a Rasa Enterprise license, please see the Enterprise instructions where applicable.1. Download
Download the install script:
- Rasa X
- Rasa Enterprise
2. Install
To install all of the files into the default folder, /etc/rasa
, run:
You will be prompted to accept the terms and conditions. Read the terms, then hit return to continue.
note
To choose your own installation folder instead of /etc/rasa
, set the RASA_HOME
environment variable:
Replace /etc/rasa
with ${RASA_HOME}
in further commands.
3. Start
Start up Rasa X and wait until all containers are running (-d
will run Rasa X in the background):
4. Access
Set your admin password:
- Rasa X
- Rasa Enterprise
Navigate to the hostname or IP where your server is reachable and log in using your newly created password.
Go to Next StepsDocker Compose Manual Install
We provide template docker-compose files which you can use directly. The Docker images for Rasa X are freely available via Docker Hub. The images for Rasa Enterprise are hosted on a private registry and are accessible with an enterprise license. If you have a Rasa Enterprise license, please see the Enterprise instructions where applicable.
1. Prerequisites
Make sure python3
, docker
, and docker-compose
are
installed on your server. Detailed instructions can be
found in the Docker documentation.
You should be able to run the following command(s):
- Linux
- Windows PowerShell
Note that your python version should be above 3.6 to use Rasa and Rasa X.
2. Set Project Directory
Create the project directory and switch to it:
- Linux
- Windows PowerShell
/etc/rasa
3. Download
Download the Rasa X docker-compose and commands files:
- Rasa X
- Rasa Enterprise
- Linux
- Windows PowerShell
4. Configure
Docker Environment File
Create the docker environment file .env
in your project directory with the
following content (choosing a RASA_VERSION
compatible with your
RASA_X_VERSION
- see the Compatibility Matrix):
For <random_string>
please use a distinct, randomly generated, secure
character sequence for each variable. A convenient way of generating random strings is using
openssl
:
For more information about these environment variables and others used by Rasa X, see Environment Variables.
note
The PASSWORD_SALT
is used to hash passwords. If you change this variable after setting it, you
will have to create new logins for each of your users.
Credentials
Create a credentials file credentials.yml
in your project directory containing:
These are the credentials used for messaging with the bot via the Rasa X UI. You can also add credentials for other messaging and voice channels such as your custom connector or the REST input channel.
Endpoints
Create an endpoints file endpoints.yml
in your project directory containing:
If you want to know more about the environment variables used here, see Environment Variables.
Deployment Environments
Create an environments file at environments.yml
in your project directory containing:
If you are using Rasa Enterprise, you can also add further environments as described in Deployment Environments.
Mounted Directories
Create a few empty folders that we will mount into the containers:
- Linux
- Windows PowerShell
Terms
Read the Rasa Enterprise terms
or Rasa X terms. To agree to
the terms, create an agreement file in the terms
folder:
- Linux
- Windows PowerShell
Permissions on Mounted Directories
Set group and permissions of the mounted directories:
- Linux
- Windows PowerShell
The Rasa containers are following Docker’s best practices and are not running as `root` user. Hence, please make sure that the `root` group has read and write access to the following directories and their content:
/etc/rasa/credentials.yml
/etc/rasa/endpoints.yml
/etc/rasa/environments.yml
/etc/rasa/auth
/etc/rasa/certs
/etc/rasa/credentials
/etc/rasa/models
/etc/rasa/logs
/etc/rasa/terms
To set the permissions and group for everything in `/etc/rasa` you can use this command, but make sure to correct it for the `/etc/rasa/db` directory as described in the next step:
If you are mounting different or extra directories, please adapt their permissions accordingly.
Postgres Database Storage
Configure persistent Postgres database storage
- Linux
- Windows PowerShell
On Linux, a local directory is used for persistent Postgres database storage.
You must set the correct owner and permissions of the database persistence directory using this command:
(Optional) Custom Action Server
If you are using custom actions, make sure to follow the instructions to connect a custom action server.
If you don’t want to configure custom actions yet, make sure to add this variable to your .env
to use
the demo app
image:
5. Start
Start up Rasa X and wait until all containers are running (-d
will run Rasa X in the background):
- Linux
- Windows PowerShell
6. Access
Set your admin password with this command from your project directory:
- Rasa X
- Rasa Enterprise
- Linux
- Windows PowerShell
Navigate to the hostname or IP where your server is reachable and log in using your newly created password.
Next Steps
Deploy your assistant using Rasa X.
Set up Integrated Version Control to connect your Rasa X instance to a remote Git repository.
Connect a Custom Action Server if you are using custom actions.
If you’d like to run your Rasa X server on HTTPS, check out Securing with SSL.