How do I set custom environment variables?

  • Environment Variables (Introduction):

Environment variables stores the values of the frequently used parameters, that are provided to a software program at runtime. Setting and using such placeholders instead of specifying the required values in the application code each time they are needed, makes your application more portable and flexible. It brings even more convenience if these values may differ from one host to another.

Each CloudJiffy-managed software stack is provided with a number of default variables, which display all the significant container information to help developers with application hosting.

CloudJiffy PaaS also gives me the possibility to declare your own custom environment variables (user-defined parameters) by means of adding the needed values to a special configuration file and in such a way, keeping them out of the code. Inside this file, you can set placeholders for your folder names, usernames, passwords, hosts, IP addresses, etc instead of hardcoding their values to every file they are required in.


  • Default Environment Variables:

Within variables CloudJiffy provides the data on the created stack. Most of them are just informational (marked within tables below) and do not have any actual effect on the container. For example, using the TOMCAT_VERSION variable you can compare versions of the running Tomcat server and the one required by your application (to ensure compatibility), but changing its value won’t upgrade your container.


  • There is a number of options available for all software stack templates as follows:


Value Example




Defines if new nodes upon horizontal scaling should be clones of a layer master (true) or created from scratch (false)



Lists ports from the EXPOSE directive of the image's dockerfile, which will be opened via container firewall during environment creation (informational)


3306/tcp, 33061/udp, 33062

Specifies custom ports, which will be opened via container firewall during environment creation



A default shell variable, with a list of paths to directories with executable programs (informational)



Stack home directory (informational)



Name of the default user for the stack (informational)



Version of the current template (informational)


Internal IP address of a master node within a layer (informational)



Unique node identifier of a master node within a layer (informational)



A short hostname for a master node within a layer (informational)



     To set custom environment variables, follow the below steps:

  2. 1. Log in to your Cloudjiffy dashboard.
  4. 2. Select the environment where you want to set the custom environment variables.
  1. 3. In the environment dashboard, click on the "Config" button located in the top menu.
  3. 4. In the configuration settings, you will find a section named "Variables".

  1. Click on the "Add" button to add a new custom environment variable.

  2. 5. In the "Name" field, enter the name of the environment variable. For example, if you want to set a variable called "ACCEPT_EULA", enter "ACCEPT_EULA" in the "Name" field.
  4. 6. In the "Value" field, enter the value for the environment variable. For example, "Y", enter "Y" in the "Value" field.
  6. 7. Click on the "Save" button to save the environment variable.


Was this article helpful?

mood_bad Dislike 0
mood Like 0
visibility Views: 8159