Environment Variables
Learn how to set and manage environment variables crucial for the optimal functioning of Saiku in your projects.
Setting Up Environment Variables for Saiku
Environment variables are essential for configuring Saiku to work effectively with various services and APIs. This guide will walk you through the process of setting up these variables.
Understanding Environment Variables
Environment variables are used to store configuration settings outside of your application code. They help in managing sensitive data like API keys and project identifiers.
Common Environment Variables for Saiku
OPENAI_API_KEY
: Your personal API key for OpenAI services.
Creating the Environment File
- Create a
.env
File: In your project’s root directory, create a new file named.env
.
- Add Your Variables: Open the
.env
file and insert your environment variables.
Loading Environment Variables
To make use of these variables in your Saiku project, load them at the start of your application.
It’s crucial to keep your .env
file secure. Do not commit it to version control, as it often contains sensitive information like API keys.
Properly setting up environment variables is key to ensuring that Saiku operates smoothly, particularly when interfacing with external services and APIs.
Was this page helpful?