Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(platform/frontend) Remove dotenv #8459

Merged
merged 2 commits into from
Oct 28, 2024

Conversation

aarushik93
Copy link
Contributor

Background

dontenv loads environment variables only from environment variable files and it's messing with docker and k8s environments when not adding these files dynamically

Changes 🏗️

Remove dotenv and let nextjs handle environment variabels. This still loads from .env* files locally and in different environments but also from system environment when needed. You can read here: https://nextjs.org/docs/app/building-your-application/configuring/environment-variables#environment-variable-load-order

Testing 🔍

Note

Only for the new autogpt platform, currently in autogpt_platform/

  • Create from scratch and execute an agent with at least 3 blocks
  • Import an agent from file upload, and confirm it executes correctly
  • Upload agent to marketplace
  • Import an agent from marketplace and confirm it executes correctly
  • Edit an agent from monitor, and confirm it executes correctly

Configuration Changes 📝

Note

Only for the new autogpt platform, currently in autogpt_platform/

If you're making configuration or infrastructure changes, please remember to check you've updated the related infrastructure code in the autogpt_platform/infra folder.

Examples of such changes might include:

  • Changing ports
  • Adding new services that need to communicate with each other
  • Secrets or environment variable changes
  • New or infrastructure changes such as databases

@aarushik93 aarushik93 requested a review from a team as a code owner October 27, 2024 21:42
@aarushik93 aarushik93 requested review from Torantulino and majdyz and removed request for a team October 27, 2024 21:42
Copy link

PR Reviewer Guide 🔍

Here are some key observations to aid the review process:

⏱️ Estimated effort to review: 2 🔵🔵⚪⚪⚪
🧪 No relevant tests
🔒 No security concerns identified
⚡ Recommended focus areas for review

Configuration Change
Removal of explicit environment variable loading using dotenv. Verify that NextJS's built-in environment variable handling works as expected across all environments.

@github-actions github-actions bot added platform/frontend AutoGPT Platform - Front end platform/backend AutoGPT Platform - Back end size/s labels Oct 27, 2024
@aarushik93 aarushik93 enabled auto-merge (squash) October 28, 2024 12:52
@aarushik93 aarushik93 merged commit 525b894 into dev Oct 28, 2024
7 checks passed
@aarushik93 aarushik93 deleted the aarushikansal/update-nextjs-environment-variable-use branch October 28, 2024 13:03
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
platform/backend AutoGPT Platform - Back end platform/frontend AutoGPT Platform - Front end Review effort [1-5]: 2 size/s
Projects
Status: Done
Development

Successfully merging this pull request may close these issues.

2 participants