Search…
Environment Handles
Create custom, unique resource pools for your environments.

Overview

An environment "handle" is a pre-generated, unique identifier that can be used for deterministic resource pools, such as environment URLs. A common reason you may want to use an environment handle is to create deterministic URLs for your environments for OAuth applications.
In Release, professional accounts can create a custom handle name and determine the number of resources it will have. One of these resource handles can be "checked-out" by an environment where it ends up being displayed in your domain name.

How to Create Environment Handles

The following example illustrates the end result of your environment handle being inserted into the environment's domain URL. This example is actually no different than a regular ephemeral environment space, the only difference is that ${env_id} will be allocated from the handle pool.
Example URL: https://service-${env_id}-appname.releaseapp.io
In order to create an Environment Handle, go to the Env Handles tab in Account Settings and click the NEW button.
List of Environment Handles
A modal will open asking for your handle name and how many handle resources you need.
Create Handle Modal
After you create it, you can click the VIEW button to see more details, such as the name for each Handle resource and which environment has it currently checked out. Notice how each resource simply begins with the base handle name, followed by an incrementing index number. This will appear in the environment's url domain when it is utilizing it.

Apply the environment handle to your application template

After you have successfully initialized your Environment Handle, you may want your environments to start using them. In order for an Environment to "check-out" a unique handle you can add the following to your "App Settings -> Application Template":
1
environment_templates:
2
- name: ephemeral
3
datasets:
4
- name: handle_name
Copied!
Please note that URL handle pools are only applied during environment creation and cannot be changed or applied retroactively to an existing environment.

Using Per-Environment Variables

Now that you have an Environment Handle assigned to your application template, you can now set specific environment variables for each individual environment. For example, you may have a set of third party service tokens that require a unique ID for each environment for testing purposes. This is a common pattern for services like Firebase or Twilio, for example. You can set each environment with a specific set of environment variables that will be applied to a specific environment.
To add or remove environment variables from each handle, simply click the down chevron to expand the section below each environment handle, then click the plus sign to add or trash can to delete. When adding an environment variable, simply add the key and value as usual as shown below. You can click the "x" to cancel or checkmark to save your changes.
Adding a specific environment value to the "llama" environment handle.