import{_ as e,r as t,o,c,b as n,d as s,a as l,e as p}from"./app-BDXVaVU8.js";const i={},r=p(`
轻雪支持yaml
、json
和toml
作为配置文件,取决于你个人的喜好
首次运行后生成config.yml
和config
目录,你可修改配置项后重启轻雪,绝大多数情况下,你只需要修改superusers
及nickname
字段即可
启动时会加载项目目录下config.yml/yaml/json/toml
和config
目录下的所有配置文件,你可在config
目录下创建多个配置文件,轻雪会自动合并这些配置文件
nonebot:
command_start: [ "/", "" ]
host: 127.0.0.1
port: 20216
nickname: [ "liteyuki" ]
superusers: [ "1919810" ]
liteyuki:
log_level: "INFO"
log_icon: true
auto_report: true
auto_update: true
plugins: [ ]
plugin_dirs: [ ]
以下为默认值,如需自定义请手动添加
nonebot:
onebot_access_token: ""
default_language: "zh-CN"
alconna_auto_completion: false
safe_mode: false
custom_config_1: "custom_value1"
custom_config_2: "custom_value2"
liteyuki:
allow_update: true
debug: false
dev_mode: false
...
提示
如果要使用NoneBot和dotenv配置文件,请自行创建.env.{ENVIRONMENT}
,并在config.yml
中添加nonebot.environment:{ENVIRONMENT}
字段
生产环境中推荐反向WebSocket 不同的实现端给出的字段可能不同,但是基本上都是一样的,这里给出一个参考值
字段 | 参考值 | 说明 |
---|
协议 | 反向WebSocket | 推荐使用反向ws协议进行通信,即轻雪作为服务端 |
地址 | ws://127.0.0.1:20216/onebot/v11/ws | 地址取决于配置文件,本机默认为127.0.0.1:20216 |
AccessToken | "" | 如果你给轻雪配置了AccessToken ,请在此填写相同的值 |
`,13),u={href:"https://onebot.adapters.nonebot.dev/",target:"_blank",rel:"noopener noreferrer"},d=n("li",null,"轻雪不局限于OneBot适配器,你可以使用NoneBot2支持的任何适配器",-1);function m(k,v){const a=t("ExternalLinkIcon");return o(),c("div",null,[r,n("ul",null,[n("li",null,[s("要使用其他通信方式请访问"),n("a",u,[s("OneBot Adapter"),l(a)]),s("获取详细信息")]),d])])}const b=e(i,[["render",m],["__file","config.html.vue"]]),y=JSON.parse('{"path":"/deploy/config.html","title":"配置","lang":"zh-CN","frontmatter":{"title":"配置","icon":"cog","order":2,"category":"使用指南","tag":["配置","部署"],"description":"轻雪支持yaml、json和toml作为配置文件,取决于你个人的喜好 首次运行后生成config.yml和config目录,你可修改配置项后重启轻雪,绝大多数情况下,你只需要修改superusers及nickname字段即可 启动时会加载项目目录下config.yml/yaml/json/toml和config目录下的所有配置文件,你可在config目...","head":[["link",{"rel":"alternate","hreflang":"en-us","href":"https://vuepress-theme-hope-docs-demo.netlify.app/en/deploy/config.html"}],["meta",{"property":"og:url","content":"https://vuepress-theme-hope-docs-demo.netlify.app/deploy/config.html"}],["meta",{"property":"og:site_name","content":"LiteyukiBot 轻雪机器人"}],["meta",{"property":"og:title","content":"配置"}],["meta",{"property":"og:description","content":"轻雪支持yaml、json和toml作为配置文件,取决于你个人的喜好 首次运行后生成config.yml和config目录,你可修改配置项后重启轻雪,绝大多数情况下,你只需要修改superusers及nickname字段即可 启动时会加载项目目录下config.yml/yaml/json/toml和config目录下的所有配置文件,你可在config目..."}],["meta",{"property":"og:type","content":"article"}],["meta",{"property":"og:locale","content":"zh-CN"}],["meta",{"property":"og:locale:alternate","content":"en-US"}],["meta",{"property":"og:updated_time","content":"2024-08-16T18:24:25.000Z"}],["meta",{"property":"article:tag","content":"配置"}],["meta",{"property":"article:tag","content":"部署"}],["meta",{"property":"article:modified_time","content":"2024-08-16T18:24:25.000Z"}],["script",{"type":"application/ld+json"},"{\\"@context\\":\\"https://schema.org\\",\\"@type\\":\\"Article\\",\\"headline\\":\\"配置\\",\\"image\\":[\\"\\"],\\"dateModified\\":\\"2024-08-16T18:24:25.000Z\\",\\"author\\":[]}"]]},"headers":[{"level":2,"title":"基础配置项","slug":"基础配置项","link":"#基础配置项","children":[]},{"level":2,"title":"其他配置","slug":"其他配置","link":"#其他配置","children":[]},{"level":2,"title":"与NoneBot对接的OneBot实现端配置","slug":"与nonebot对接的onebot实现端配置","link":"#与nonebot对接的onebot实现端配置","children":[]},{"level":2,"title":"其他","slug":"其他","link":"#其他","children":[]}],"git":{"createdTime":1723832665000,"updatedTime":1723832665000,"contributors":[{"name":"snowy","email":"snowykami@outlook.com","commits":1}]},"readingTime":{"minutes":2.44,"words":733},"filePathRelative":"deploy/config.md","localizedDate":"2024年8月16日","autoDesc":true}');export{b as comp,y as data};