mirror of
https://github.com/Significant-Gravitas/AutoGPT.git
synced 2026-04-08 03:00:28 -04:00
Reads data from .env (#7357)
This commit is contained in:
8
rnd/autogpt_builder/next.config.js
Normal file
8
rnd/autogpt_builder/next.config.js
Normal file
@@ -0,0 +1,8 @@
|
||||
const dotenv = require('dotenv');
|
||||
dotenv.config();
|
||||
|
||||
module.exports = {
|
||||
env: {
|
||||
AGPT_SERVER_URL: process.env.AGPT_SERVER_URL,
|
||||
},
|
||||
};
|
||||
@@ -13,6 +13,7 @@
|
||||
"@radix-ui/react-slot": "^1.1.0",
|
||||
"class-variance-authority": "^0.7.0",
|
||||
"clsx": "^2.1.1",
|
||||
"dotenv": "^16.4.5",
|
||||
"next": "14.2.4",
|
||||
"next-themes": "^0.3.0",
|
||||
"react": "^18",
|
||||
|
||||
@@ -73,7 +73,7 @@ const FlowEditor: React.FC<{ flowID?: string }> = ({ flowID }) => {
|
||||
const [agentName, setAgentName] = useState<string>('');
|
||||
const [agentDescription, setAgentDescription] = useState<string>('');
|
||||
|
||||
const apiUrl = 'http://localhost:8000';
|
||||
const apiUrl = process.env.AGPT_SERVER_URL!;
|
||||
const api = new AutoGPTServerAPI(apiUrl);
|
||||
|
||||
useEffect(() => {
|
||||
|
||||
Reference in New Issue
Block a user