ReferenceEnv var references
Precedence
Ferry builds the environment in three layers, then resolves the references.
1. Ferry. The variables that Ferry injects: PORT and FERRY_*.
1 / 4
Ferry builds the environment of a container in layers. A later layer wins. This is the precedence.
Ferry resolves the references after the merge. Thus a reference can be in an env group, and each linked service gets it.
See the merged set
ferry env NAME --effectiveThe command prints the merged environment before Ferry resolves the references.
The variables that Ferry injects
| Variable | For |
|---|---|
PORT | Services that listen on a port |
FERRY=true, FERRY_SERVICE_ID, FERRY_SERVICE_NAME, FERRY_SERVICE_TYPE, FERRY_DEPLOY_ID, FERRY_INTERNAL_HOSTNAME | Each service |
FERRY_GIT_COMMIT, FERRY_GIT_BRANCH | Deploys from git |
FERRY_EXTERNAL_HOSTNAME, FERRY_EXTERNAL_URL | Public services |