1 Star 0 Fork 3

Gitee 极速下载 / Casdoor

Create your Gitee Account
Explore and code with more than 6 million developers,Free private repositories !:)
Sign up
此仓库是为了提升国内下载速度的镜像仓库,每日同步一次。 原始仓库: https://github.com/casbin/casdoor
Clone or Download
Cancel
Notice: Creating folder will generate an empty file .keep, because not support in Git
Loading...
README.md

📦⚡️ Casdoor

A UI-first centralized authentication / Single-Sign-On (SSO) platform based on OAuth 2.0 / OIDC.

semantic-release docker pull casbin/casdoor GitHub Workflow Status (branch) GitHub Release Docker Image Version (latest semver)

Go Report Card license GitHub issues GitHub stars GitHub forks

Online demo

Deployed site: https://door.casbin.com/

Quick Start

Run your own casdoor program in a few minutes:smiley:

Download

There are two methods, get code via go subcommand get:

go get github.com/casbin/casdoor

or git:

git clone https://github.com/casbin/casdoor

Finally, change directory:

cd casdoor/

We provide two start up methods for all kinds of users.

Manual

Simple configuration

Edit conf/app.conf, modify dataSourceName to correct database info, which follows this format:

username:password@tcp(database_ip:database_port)/

Run

Casdoor provides two run modes, the difference is binary size and user prompt.

Dev Mode

Edit conf/app.conf, set runmode=dev. Firstly build front-end files:

cd web/ && yarn && yarn run start

❗ A word of caution ❗: Casdoor's front-end is built using yarn. You should use yarn instead of npm. It has a potential failure during building the files if you use npm.

Then build back-end binary file, change directory to root(Relative to casdoor):

go run main.go

That's it! Try to visit http://127.0.0.1:7001/. :small_airplane:
But make sure you always request the backend port 8000 when you are using SDKs.

Production Mode

Edit conf/app.conf, set runmode=prod. Firstly build front-end files:

cd web/ && yarn && yarn run build

Then build back-end binary file, change directory to root(Relative to casdoor):

go build main.go && sudo ./main

Notice, you should visit back-end port, default 8000. Now try to visit http://SERVER_IP:8000/

Docker

This method requires docker and docker-compose to be installed first.

Simple configuration

Edit conf/app.conf, modify dataSourceName to the fixed content:

dataSourceName = root:123@tcp(db:3306)/

If you need to modify conf/app.conf, you need to re-run docker-compose up.

Run

docker-compose up

That's it! Try to visit http://localhost:8000/. :small_airplane:

Docker Hub

This method requires docker and docker-compose to be installed first.

docker pull casbin/casdoor

Detailed documentation

We also provide a complete document as a reference.

Other examples

These all use casdoor as a centralized authentication platform.

  • Casnode: Next-generation forum software based on React + Golang.
  • Casbin-OA: A full-featured OA(Office Assistant) system.
  • ......

Contribute

For casdoor, if you have any questions, you can give Issues, and you can also directly Pull Requests(but we recommend give issues first to communicate with the community).

I18n notice

If you are contributing to casdoor, please note that we use Crowdin as translating platform and i18next as translating tool. When you add some words using i18next in the web/ directory, please remember to add what you have added to the web/src/locales/en/data.json file.

License

Apache-2.0

Repository Comments ( 0 )

Sign in for post a comment

About

Casdoor 是一个基于 OAuth 2.0 / OIDC 的 UI 优先集中认证 / 单点登录 (SSO) 平台,简单点说,就是 Casdoor 可以帮你解决 用户管理 的难题 expand collapse
JavaScript and 6 more languages
Apache-2.0
Cancel

Releases

No release

Contributors

All

Activities

Load More
can not load any more
JavaScript
1
https://toscode.gitee.com/mirrors/Casdoor.git
git@toscode.gitee.com:mirrors/Casdoor.git
mirrors
Casdoor
Casdoor
master

Search

141041 ab9339c7 1850385 141043 25c028d5 1850385