Repository navigation
Configuration
houyhl edited this page Oct 17, 2026
·
6 revisions
This page tells you where each kind of setting lives and how to make a change take effect. Paths assume the default installation directory /opt/LLMOJ; if you installed elsewhere with --prefix, use your own directory everywhere.
| Page | What it covers |
|---|---|
| Installation | The installer and its options |
| Backend configuration |
config/backend.yaml: accounts, security, database, mail, storage, contests and display |
| Registration approval | The registration mode set in Site management, its default in backend.yaml, and reviewers |
| Two-factor sign-in | Authenticator codes and passkeys, which users set up themselves, and the two-factor.key file |
| Judge configuration |
config/judge.yaml, resizing for more or fewer CPUs, services and checks |
| AI | AI models, web search, permissions and jobs, set by each user in the site |
| AI environment | AI directories, keys and environment variables on the server |
| Environment variables | Environment variables for running, installing and building, and maintenance script options |
| Frontend configuration | Building the frontend and optional CDN settings |
| Operations | Nginx, MariaDB, Redis, MinIO, systemd, and changes after installation |
-
Built-in defaults are what the code uses when a setting is missing. Most settings in
backend.yamlandjudge.yamlhave no built-in default, so deleting a line doesn't bring back the value from an example. -
Examples in the repository (
*.example) may contain values meant for another site. - Installer values are calculated during the first installation from the directory, ports, CPUs and memory. Running the installer again keeps the existing files.
-
What's actually in effect is your configuration files together with the systemd units and their drop-in files. The registration mode saved in Site management overrides the one in
backend.yaml, and AI settings are stored per user.
| What you changed | What to do |
|---|---|
config/backend.yaml |
Check that the YAML is valid, restart libreoj-backend and refresh the browser. A registration mode saved in Site management still takes precedence. |
| Registration mode in Site management | Nothing: it applies as soon as it's saved. See Registration approval. |
config/judge.yaml |
Follow Judge configuration: let running judging finish first. Changes to slots, CPUs or directories also need new systemd units. |
| systemd environment, resource limits or drop-ins | Run systemctl daemon-reload, then restart the service. daemon-reload alone doesn't restart anything. |
config/nginx.conf |
Check it with nginx -t, then reload Nginx. Keep the domain and the storage download address consistent. |
| MariaDB, Redis or MinIO | Restart the service at a quiet time and check that the backend can still use it. |
| Frontend build settings or static files | Rebuild, copy the result to the directory Nginx serves, and refresh the browser. |
| AI models, search and permissions | Save them in the site. Running jobs check permissions again as they go; see AI. |
The installer's options are for the first installation only. Running the installer again with a different --judge-slots, --port or --public-url doesn't reconfigure the site: it may refuse the new values, and it keeps the existing YAML files. Don't delete the installation state, secrets.json, the AI master key or data to get round this.
- More or fewer CPUs or memory: resize the judge.
- Site name, ports, domain, mail, upload limits or service memory: Operations.
- AI models, Tavily or MCP: AI.
Back up the database, file storage, configuration and AI keys together: the source code alone can't restore a site. Never put real passwords or keys in the wiki or on GitHub.
简体中文
- LLMOJ Wiki
- AI 环境与固定限制
- AI
- 后端配置
- 功能升级与数据库修改
- 配置总览
- 比赛赛制
- 分布式评测
- Docker 源
- 环境变量与维护脚本
- 前端配置
- HTTPS 与反向代理
- Hack
- 安装与端口配置
- 评测配置与扩缩容
- 安装后运维
- 发布源码与 Wiki
- 新用户注册审核
- 远程评测机
- NOI / OI 比赛自测(Self Eval)
- 题解
- Fake 处罚
- 提交记录
- 团队
- 两步验证
- 升级
English
- LLMOJ Wiki
- AI
- AI environment and fixed limits
- Backend configuration
- Feature upgrades and database changes
- Configuration overview
- Contest rules
- Distributed judging
- Docker sources
- Environment variables and maintenance scripts
- Frontend configuration
- HTTPS and reverse proxies
- Hacks
- Installation and ports
- Judge configuration and resizing
- Operations
- Publishing source and the wiki
- Registration approval
- Remote judges
- Self Eval in NOI / OI contests
- Solutions
- Fake moderation
- Submissions
- Teams
- Two-factor sign-in
- Upgrading