Skip to main content

Run Locally

note

Self-hosting Speakeasy means managing the service yourself and take care of upgrades, scaling, security etc. If you are less technical or looking for a hands-off experience, we recommend Speakeasy Cloud.

The Speakeasy platform is designed to be hosted on K8S. However, local evaluation of the platform can be performed through Docker. You don't have to be a Docker expert to launch your own instance of Speakeasy. You should have a basic understanding of the docker and docker-compose command line and networking to successfully setup your own instance of Speakeasy.

If you run into any issues you can reach out to us on Slack !

Requirements

The only thing you need to install Speakeasy locally is an environment with Docker installed. The server must have a CPU with x86_64 architecture and support for SSE 4.2 instructions. We recommend using a minimum of 2GB of RAM but the requirements will depend on your site traffic.

Up and running

1. Clone the hosting repo

To get started quickly, download the speakeasy-api/helm-charts repo as a starting point. It has everything you need to boot up your own Speakeasy server

git clone https://github.com/speakeasy-api/helm-charts.git

In the downloaded directory you'll find two important sets of files:

  • docker-compose.yml - installs and orchestrates networking between your Speakeasy server, Postgres database and web ui. It comes with sensible defaults that are ready to go, although you're free to tweak the settings if you wish.
  • charts/speakeasy-k8s - set of helm charts to run Speakeasy on any K8s cluster. For more see here.

2. Start the server

Once you've entered your secret key base, base URL and admin credentials, you're ready to start up the server:

docker-compose up -d

When you run this command for the first time, it does the following:

  • Creates a Postgres database for user data.
  • Creates a server the runs the Speakeasy platform including the UI and API
  • Runs migrations on databases to prepare the schema.
  • Starts the UI on port 35291 and server on 35290.

3. Add an Admin User

Speakeasy has Self Signup enabled by default when running in docker.

Alternatively, you can add an admin user (or grant/remove privileges to an existing user) by running the following command:

./scripts/add-user.bash

Follow the prompts to add an admin user with a given email address. If you use the default Authentication Provider (GitHub), you will need to use your GitHub associated email address.

4. Updating Speakeasy

Speakeasy is updated regularly, but it's up to you to apply these updates on your server.

docker-compose down --remove-orphans
docker-compose pull speakeasy
docker-compose up -d

The self-hosted version is somewhat of a LTS, only getting the changes after they have been battle tested on the hosted version. If you want features as soon as they are available, consider becoming a hosted customer.