Files
dokploy/apps/docs/content/docs/cli/commands/authentication.cn.mdx
2024-09-02 13:17:56 +08:00

26 lines
870 B
Plaintext
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
---
title: 身份验证
description: 使用 Dokploy CLI 进行身份验证的指南
---
Dokploy CLI 使用基于令牌的身份验证系统。要进行身份验证,您需要创建一个访问令牌并安全存储它。
## 创建访问令牌
要创建访问令牌,首先您需要具备相应的权限,如果您是管理员,则不需要权限。
默认情况下,访问令牌不会过期。
您可以前往 `dashboard/settings/profile` 并点击 `生成` 按钮。
<ImageZoom src="/assets/cli/token.png" width={800} height={630} alt='home og image' className="rounded-lg" />
## 存储访问令牌
当您创建访问令牌时Dokploy 将自动生成一个包含访问令牌和服务器 URL 的 config.json 文件。
## 命令
1. `dokploy authenticate` - 使用 Dokploy CLI 进行身份验证。
2. `dokploy verify` - 验证访问令牌是否有效。