名称: agentuity-cli-cloud-env-set 描述: 设置环境变量。需要身份验证。用于Agentuity云平台操作 版本: “0.0.103” 许可证: Apache-2.0 允许的工具: “Bash(agentuity:*)” 参数提示: “<键> <值>” 元数据: 命令: “agentuity cloud env set” 标签: “mutating updates-resource slow requires-auth requires-project”
云环境变量设置
设置环境变量
前提条件
- 已通过
agentuity auth login进行身份验证 - 需要项目上下文(从项目目录运行或使用
--project-id)
用法
agentuity cloud env set <键> <值>
参数
| 参数 | 类型 | 必填 | 描述 |
|---|---|---|---|
<键> |
字符串 | 是 | - |
<值> |
字符串 | 是 | - |
示例
运行生产环境命令:
bunx @agentuity/cli env set NODE_ENV production
运行端口设置命令:
bunx @agentuity/cli env set PORT 3000
运行调试命令:
bunx @agentuity/cli env set LOG_LEVEL debug
输出
返回JSON对象:
{
"success": "boolean",
"key": "string",
"path": "string"
}
| 字段 | 类型 | 描述 |
|---|---|---|
success |
布尔值 | 操作是否成功 |
key |
字符串 | 环境变量键 |
path |
字符串 | 环境变量保存的本地文件路径 |