Showing results for 
Show  only  | Search instead for 
Did you mean: 

Environment variables for app functions


Do app functions support loading environment variable from .env file?



export default async function (payload: unknown = undefined) {
  const config = {
    host: process.env.SERVER,
    port: process.env.PORT,
    username: process.env.USERNAME,
    password: process.env.PASSWORD

  return 'Hello world';





Dynatrace Helper
Dynatrace Helper

No. Dynatrace app functions are not based on Node, nor do they have access to the file system or other process-related information. You can think of them as an ephemeral execution of just this one workload, with no knowledge of its surroundings other than the platform.

If you want to access secrets and configuration, you need to use the App Settings API and the Secrets/Credentials Vault, but they might not yet be available in Customer Preview.

Featured Posts