Deploy Retool on a local machine

Learn how to deploy Self-hosted Retool on your local machine.

Follow the instructions in this guide to deploy self-hosted Retool on your local machine.

🚧

Local deployments are not intended for production use. You should instead deploy Retool on a virtual machine such as AWS EC2, Azure VM, or GCP Compute Engine. Virtual machine hardware and operating systems are more standardized than physical machines, which makes them more robust for production deployments.

Requirements

To deploy Retool on your local machine, you need:

  • A Retool license key, which you can obtain from my.retool.com or your Retool account manager.
  • A working installation of Docker desktop.

1. Install Retool

  1. Clone the retool-on-premise repository and change your working directory to retool.
git clone https://github.com/tryretool/retool-onpremise.git retool
cd retool
  1. Run the docker_setup script to create a docker.env file.
./docker-setup

2. Update environment variables

On Docker deployments, environment variables are set in docker.env.

  1. In docker.env, set LICENSE_KEY to your license key.

  2. In docker.env, uncomment the COOKIE_INSECURE=true line. After you set up SSL, you should set COOKIE_INSECURE to false.

  3. Copy the ENCRYPTION_KEY in docker.env generated by the install script. Save this key in a secure location outside of Retool. This key encrypts secrets for your Retool resources.

3. Set the version and start Retool

  1. In your Dockerfile, replace X.Y.Z with a Retool version tag, for example 2.116.3. Identify the appropriate release version by viewing the tags on Docker Hub. See Retool's self-hosted release notes to learn about version-specific features.

  2. Start Retool. It may take a few minutes to pull the images and start each service.

sudo docker-compose up -d
  1. Confirm the containers are running.
sudo docker-compose ps

Self-hosted Retool is now running. Go to http://0.0.0.0:3000/ to create your Retool admin account.

Additional steps

Use these additional steps to keep your local instance up-to-date.

Update Retool

  1. Update your Dockerfile with the newer version number.
FROM tryretool/backend:X.Y.Z
  1. Install the upgrade.
./update_retool.sh

Retool instances temporarily go down while they upgrade. You can check the status of your containers with sudo docker-compose ps.

Update configuration files

Occasionally, new Retool products and features require updates to the configuration files in retool-onpremise or other Retool repositories. To update these files when new features are available, pull the changes using Git.

cd retool
git pull

Refer to the product or feature-specific documentation for configuration instructions.