-
Notifications
You must be signed in to change notification settings - Fork 1.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[Feature] Sso Backend support #3366
base: dev
Are you sure you want to change the base?
Conversation
url: jdbc:mysql://${MYSQL_ADDR:127.0.0.1:3306}/${MYSQL_DATABASE:dinky}?useUnicode=true&characterEncoding=UTF-8&autoReconnect=true&useSSL=false&zeroDateTimeBehavior=convertToNull&serverTimezone=Asia/Shanghai&allowPublicKeyRetrieval=true | ||
username: ${MYSQL_USERNAME:dinky} | ||
password: ${MYSQL_PASSWORD:dinky} | ||
url: jdbc:mysql://${MYSQL_ADDR:127.0.0.1:3306}/${MYSQL_DATABASE:dinky2}?useUnicode=true&characterEncoding=UTF-8&autoReconnect=true&useSSL=false&zeroDateTimeBehavior=convertToNull&serverTimezone=Asia/Shanghai&allowPublicKeyRetrieval=true |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
rollback this file
…and get it from the configuration instead
dinky-admin/src/main/java/org/dinky/controller/SsoCpntroller.java
Outdated
Show resolved
Hide resolved
@@ -16,7 +16,7 @@ spring: | |||
# If you use pgsql database, please configure pgsql database connection information in application-pgsql.yml | |||
# If you use the h2 database, please configure the h2 database connection information in application-h2.yml, | |||
# note: the h2 database is only for experience use, and the related data that has been created cannot be migrated, please use it with caution | |||
active: ${DB_ACTIVE:h2} #[h2,mysql,pgsql] | |||
active: ${DB_ACTIVE:mysql} #[h2,mysql,pgsql] |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
rollback this line
@@ -21,7 +21,8 @@ | |||
|
|||
public enum UserType { | |||
LDAP(1, "LDAP"), | |||
LOCAL(0, "LOCAL"); | |||
LOCAL(0, "LOCAL"), | |||
SSO(2, "LOCAL"); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
sso 的 value 是 local?
@@ -52,6 +54,33 @@ const Login: React.FC = () => { | |||
height: '100%' | |||
}; | |||
}); | |||
useEffect(() => { | |||
console.log(location.hash) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
delete
… interfaces after logging out.
dinky-admin/src/main/java/org/dinky/controller/SsoCpntroller.java
Outdated
Show resolved
Hide resolved
# Conflicts: # dinky-common/src/main/java/org/dinky/data/enums/Status.java
Integrate github's oauth authentication.Other SSO authentication can be expanded in the future.
Users need to enable the sso function in the configuration
and configure the correct authentication parameters
Access the /sso/token port to log in.