> ## Documentation Index
> Fetch the complete documentation index at: https://ayakaleaf-pro.mintlify.site/llms.txt
> Use this file to discover all available pages before exploring further.

# 6. 安装后任务

### 创建你的第一个管理员账户

打开 `OVERLEAF_SITE_URL` 后接 `/launchpad` 的地址，例如 `http://192.0.2.10:30080/launchpad`，并按照 [Toolkit 的安装后任务](https://ayakaleaf-pro.mintlify.site/zh-CN/on-premises/installation/using-the-toolkit/6.-post-installation-tasks.md)注册管理员账户。然后创建一个示例项目并进行编译。

你也可以从命令行创建用户：

```bash theme={null}
kubectl -n overleaf exec deploy/overleaf -- bash -c \
  'cd /overleaf/services/web && node modules/server-ce-scripts/scripts/create-user.mjs --admin --email=admin@example.com'
```

它会输出一个用于设置密码的链接。

### 检查编译是否在沙盒中运行

编译一个项目，然后查看运行该 pod 的节点：

```bash theme={null}
kubectl -n overleaf get pod -l app=overleaf -o wide   # NODE column
# on that node:
sudo docker ps -a --filter ancestor=ghcr.io/ayaka-notes/texlive-full:2026.1
ls -ln /srv/overleaf/compiles                          # owned by uid 33 (www-data)
```

每次编译都会显示为一个名为 `project-<project id>-<user id>-...` 的短期容器。

### 日志和 shell

| Toolkit | Kubernetes |
| - | - |
| `bin/logs web` | `kubectl -n overleaf exec deploy/overleaf -- tail -f /var/log/overleaf/web.log` |
| `bin/shell` | `kubectl -n overleaf exec -it deploy/overleaf -- bash` |
| `bin/up` | `kubectl apply -f .`，然后执行 `kubectl -n overleaf rollout restart deployment/overleaf` |

容器会在 `/var/log/overleaf/` 中为每个服务写入一个日志文件（`web.log`、`clsi.log`、`real-time.log`、`document-updater.log`……）；`kubectl logs` 显示启动输出。

### Q\&A

> [accordion] 编译失败或一直无法完成。
>
> \*\*回答：\*\*请在运行该 pod 的节点上检查 Docker 是否正在运行并且拥有 `TEX_LIVE_DOCKER_IMAGE` 中指定的镜像，以及 `SANDBOXED_COMPILES_HOST_DIR_*` 是否与 `hostPath` 路径一致。pod 中的 `/var/log/overleaf/clsi.log` 会指出失败的步骤。

> [accordion] 每次重启 pod 后用户都会被退出登录。
>
> \*\*回答：\*\*Secret `overleaf-secrets` 中缺少 `OVERLEAF_SESSION_SECRET`，参见[第 2 步](https://ayakaleaf-pro.mintlify.site/zh-CN/on-premises/installation/using-kubernetes/2.-create-the-namespace-and-secrets.md)。


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.