-
Notifications
You must be signed in to change notification settings - Fork 249
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
2d783a0
commit f79d92e
Showing
7 changed files
with
91 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,30 @@ | ||
additionalProperties: | ||
formFields: | ||
- default: 2FAuth | ||
envKey: APP_NAME | ||
labelEn: APP NAME | ||
labelZh: 应用名称 | ||
required: true | ||
type: text | ||
- default: 8000 | ||
edit: true | ||
envKey: PANEL_APP_PORT_HTTP | ||
labelEn: Port | ||
labelZh: 端口 | ||
required: true | ||
rule: paramPort | ||
type: number | ||
- default: http://localhost:8000 | ||
edit: true | ||
envKey: APP_URL | ||
labelEn: APP URL | ||
labelZh: 外部地址(可以添加为反向代理网站,并启用 HTTPS) | ||
required: true | ||
rule: paramExtUrl | ||
type: text | ||
- default: SomeRandomStringOf32CharsExactly | ||
envKey: APP_KEY | ||
labelEn: APP KEY | ||
labelZh: 加密键 | ||
required: true | ||
type: text |
Empty file.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
services: | ||
2fauth: | ||
image: 2fauth/2fauth:5.2.0 | ||
container_name: ${CONTAINER_NAME} | ||
restart: always | ||
ports: | ||
- ${PANEL_APP_PORT_HTTP}:8000/tcp | ||
networks: | ||
- 1panel-network | ||
volumes: | ||
- ./data:/2fauth | ||
environment: | ||
- APP_NAME=${APP_NAME} | ||
- APP_KEY=${APP_KEY} | ||
- APP_URL=${APP_URL} | ||
- IS_DEMO_APP=false | ||
- LOG_CHANNEL=daily | ||
- LOG_LEVEL=notice | ||
- DB_DATABASE="/srv/database/database.sqlite" | ||
- CACHE_DRIVER=file | ||
- SESSION_DRIVER=file | ||
- AUTHENTICATION_GUARD=web-guard | ||
labels: | ||
createdBy: "Apps" | ||
networks: | ||
1panel-network: | ||
external: true |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
#!/bin/bash | ||
|
||
chown -R 1000:1000 data |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
# 设置 | ||
|
||
## **启用 HTTPS** | ||
|
||
- **创建应用**:外部地址填写 `https://2fauth.example.com`(请根据实际情况替换域名)。 | ||
- **创建反向代理网站**:代理地址填写 `http://127.0.0.1:8000`(请根据实际情况替换 IP 和端口)。 | ||
- **申请证书**:为 `2fauth.example.com` 创建证书,验证方式选择 HTTP 类型。 | ||
- **启用 HTTPS**:进入网站设置页面,点击 HTTPS,选择刚刚添加的证书并保存。 | ||
|
||
## **不启用 HTTPS** | ||
|
||
- 如果不启用 HTTPS,会导致无法扫描二维码等问题。在这种情况下,外部地址可以直接填写 `http://192.168.10.100:8000`,无需进行反向代理设置。 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
name: 2FAuth | ||
tags: | ||
- 安全 | ||
title: 管理双因素身份验证(2FA)帐户并生成安全代码的 Web 应用程序 | ||
description: 管理双因素身份验证(2FA)帐户并生成安全代码的 Web 应用程序 | ||
additionalProperties: | ||
key: 2fauth | ||
name: 2FAuth | ||
tags: | ||
- Security | ||
shortDescZh: 管理双因素身份验证(2FA)帐户并生成安全代码的 Web 应用程序 | ||
shortDescEn: A Web app to manage your Two-Factor Authentication (2FA) accounts and generate their security codes | ||
type: tool | ||
crossVersionUpdate: true | ||
limit: 0 | ||
recommend: 0 | ||
website: https://docs.2fauth.app/ | ||
github: https://github.com/Bubka/2FAuth | ||
document: https://docs.2fauth.app/ |
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.