webpack

Use the installation instructions below if you're installing Helios in a Node.js service using webpack.

πŸ“˜

Serverless webpack

If webpack is used to bundle Lambda functions, please refer to the serverless doc.

Navigate to your project's root directory, and install the latest Helios OpenTelemetry SDK:

npm install --save @heliosphere/opentelemetry-sdk

In your project's main entry file, paste the following code snippet before all other imports:

import '@heliosphere/opentelemetry-sdk';

In order to complete the installation of Helios SDK in the Node.js service using webpack, a few environment variables need to be set.

HS_AUTO_INIT=true,
HS_TOKEN=<API_TOKEN>,           // TODO: Insert API token from Helios.
HS_SERVICE_NAME=<SERVICE_NAME>, // TODO: Insert service name.
HS_ENVIRONMENT=<ENVIRONMENT>,   // Defaults to process.env.NODE_ENV if omitted.
HS_COMMIT_HASH=<COMMIT_HASH>,   // Defaults to process.env.COMMIT_HASH if omitted.

πŸ‘

All set

After setup is complete and once the service is up and running, it will show up in the Helios application.


Did this page help you?