Environment Variables

At runtime Apcera exposes and populates various environment variables for jobs, packages, and services.

Job variables

Environment Variable Purpose
HOME Root folder for the deployed application.
PATH system path used to search for executables.
PORT Port the app binds to. It can be specified on the route, else it is randomly chosen.
CNTM_HOST_IP IP address of the host of the isolation context.
CNTM_HOST_PORT hostip:port - hostip is the IP address of the host of the isolation context.
CNTM_PROCESS_NAME Name of the process from the Job.
CNTM_INSTANCE_UUID Instance UUID that identifies the process in the system.
CNTM_JOB_UUID UUID of the job.
CNTM_JOB_FQN FQN of the job.
ENV-SET Specify a custom envirnment variable.

Refer to the app selection and migration topic for examples of job environment variables.

Package variables

In addition to job variables, the system will also expose and populate package variables, an example of which is shown below:


Service variables

Service bindings are stored as environment variables:


There are specific binding varables for JDBC:


For example:


Refer to the Service binding documentation for details.

APC variables

Apcera saves APC settings in the file .apc. It normally saves this file in your home directory, but you can specify a different location by setting the APC_HOME environment variable. See Installing APC for more information.