Halo 2.0 的 OAuth2 第三方登录插件。
认证方式
按钮进入认证方式管理列表即可看到当前插件提供的认证方式。目前支持的认证方式:
服务商 | 文档 | Halo 所需配置 | Scope | 回调地址 |
---|---|---|---|---|
GitHub | https://docs.github.com | Client ID Client Secret |
无需手动设置 | <SITE_URL>/login/oauth2/code/github |
GitLab | https://docs.gitlab.com | Client ID Client Secret |
read_user |
<SITE_URL>/login/oauth2/code/gitlab |
Gitee | https://gitee.com/oauth/applications | Client ID Client Secret |
user_info |
<SITE_URL>/login/oauth2/code/gitee |
注意事项:
http
尝试。插件开发的详细文档请查阅:https://docs.halo.run/developer-guide/plugin/hello-world
git clone git@github.com:halo-sigs/plugin-oauth2.git
# 或者当你 fork 之后
git clone git@github.com:{your_github_id}/plugin-oauth2.git
cd path/to/plugin-oauth2
# macOS / Linux
./gradlew build
# Windows
./gradlew.bat build
修改 Halo 配置文件:
halo:
plugin:
runtime-mode: development
fixedPluginPath:
- "/path/to/plugin-oauth2"