diff --git a/.travis.yml b/.travis.yml
index 96de51f..66cb7a0 100644
--- a/.travis.yml
+++ b/.travis.yml
@@ -8,7 +8,7 @@ language: go
go:
- 1.13.x
-go_import_path: github.com/leeif/pluto
+go_import_path: github.com/MuShare/pluto
# Skip the install step. Don't `go get` dependencies. Only build with the code
# in vendor/
diff --git a/CHANGELOG.md b/CHANGELOG.md
index 2541170..7c0064a 100644
--- a/CHANGELOG.md
+++ b/CHANGELOG.md
@@ -1,6 +1,6 @@
-## [v1.0.0](https://github.com/leeif/pluto/compare/v0.5.3...v1.0.0)
+## [v1.0.0](https://github.com/MuShare/pluto/compare/v0.5.3...v1.0.0)
> 2020-04-22
diff --git a/Dockerfile b/Dockerfile
index 9484c90..b97c0fe 100644
--- a/Dockerfile
+++ b/Dockerfile
@@ -2,9 +2,9 @@ FROM golang:1.13 as build
ARG VERSION
-ADD . /go/src/github.com/leeif/pluto
+ADD . /go/src/github.com/MuShare/pluto
-WORKDIR /go/src/github.com/leeif/pluto
+WORKDIR /go/src/github.com/MuShare/pluto
RUN export GO111MODULE=on GOPROXY=https://proxy.golang.org && \
go build -ldflags="-X 'main.VERSION=${VERSION}'" -o pluto-server cmd/pluto-server/main.go && \
@@ -19,10 +19,10 @@ RUN wget https://github.com/jwilder/dockerize/releases/download/$DOCKERIZE_VERSI
&& tar -C /usr/local/bin -xzvf dockerize-linux-amd64-$DOCKERIZE_VERSION.tar.gz \
&& rm dockerize-linux-amd64-$DOCKERIZE_VERSION.tar.gz
-COPY --from=build /go/src/github.com/leeif/pluto/pluto-server /usr/bin/
+COPY --from=build /go/src/github.com/MuShare/pluto/pluto-server /usr/bin/
-COPY --from=build /go/src/github.com/leeif/pluto/pluto-migrate /usr/bin/
+COPY --from=build /go/src/github.com/MuShare/pluto/pluto-migrate /usr/bin/
-COPY --from=build /go/src/github.com/leeif/pluto/views views/
+COPY --from=build /go/src/github.com/MuShare/pluto/views views/
ENTRYPOINT ["/usr/bin/pluto-server"]
diff --git a/Makefile b/Makefile
index f04a23c..1d8ba8f 100644
--- a/Makefile
+++ b/Makefile
@@ -1,27 +1,27 @@
VERSION=$(shell cat VERSION)
docker-build:
- docker build --build-arg VERSION=$(VERSION) -t leeif/pluto:latest .
- docker tag leeif/pluto:latest leeif/pluto:$(VERSION)
+ docker build --build-arg VERSION=$(VERSION) -t mushare/pluto:latest .
+ docker tag mushare/pluto:latest mushare/pluto:$(VERSION)
docker-build-staging:
- docker build --build-arg VERSION=staging -t leeif/pluto:staging .
+ docker build --build-arg VERSION=staging -t mushare/pluto:staging .
docker-push:
- docker push leeif/pluto:latest
- docker push leeif/pluto:$(VERSION)
+ docker push mushare/pluto:latest
+ docker push mushare/pluto:$(VERSION)
docker-push-staging:
- docker push leeif/pluto:staging
+ docker push mushare/pluto:staging
docker-clean:
- docker rmi leeif/pluto:latest || true
- docker rmi leeif/pluto:$(VERSION) || true
+ docker rmi mushare/pluto:latest || true
+ docker rmi mushare/pluto:$(VERSION) || true
docker rm -v $(shell docker ps --filter status=exited -q 2>/dev/null) 2>/dev/null || true
docker rmi $(shell docker images --filter dangling=true -q 2>/dev/null) 2>/dev/null || true
docker-clean-staging:
- docker rmi leeif/pluto:staging || true
+ docker rmi mushare/pluto:staging || true
docker rm -v $(shell docker ps --filter status=exited -q 2>/dev/null) 2>/dev/null || true
docker rmi $(shell docker images --filter dangling=true -q 2>/dev/null) 2>/dev/null || true
diff --git a/README.md b/README.md
index c9ed397..696d1ed 100644
--- a/README.md
+++ b/README.md
@@ -1,7 +1,7 @@
# Pluto
-[](https://travis-ci.org/leeif/pluto)
-[](https://goreportcard.com/report/github.com/leeif/pluto)
+[](https://travis-ci.org/mushare/pluto)
+[](https://goreportcard.com/report/github.com/MuShare/pluto)
[](https://gitter.im/pluto-discuss/community?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge)
Pluto is a JWT based authorization/authentication service. Besides providing a basic user registration and login feature, Pluto also provides a RBAC management to control the user's permission. Pluto implements the OAuth2 specified APIs for authorization.
@@ -12,23 +12,23 @@ Pluto is a JWT based authorization/authentication service. Besides providing a b
* Oauth2 APIs
* JWT-based authorization
* Role-based access control (RBAC)
-* Admin page [link](https://github.com/leeif/pluto-admin)
+* Admin page [link](https://github.com/MuShare/pluto-admin)
## Getting started
-The [Installation doc](https://github.com/leeif/pluto/blob/master/docs/installation.md) have a guide on how to setup the Pluto server via Docker images, Kubernetes or from source.
+The [Installation doc](https://github.com/MuShare/pluto/blob/master/docs/installation.md) have a guide on how to setup the Pluto server via Docker images, Kubernetes or from source.
### Documents
-All documents can be found in [/docs](https://github.com/leeif/pluto/blob/master/docs)
+All documents can be found in [/docs](https://github.com/MuShare/pluto/blob/master/docs)
Here are some helpful documents for reading.
-* [API Document](https://github.com/leeif/pluto/blob/master/docs/api.md)
-* [Oauth2](https://github.com/leeif/pluto/blob/master/docs/oauth.md)
-* [Configuration](https://github.com/leeif/pluto/blob/master/docs/configuration.md)
-* [Replace Views](https://github.com/leeif/pluto/blob/master/docs/view.md) is a guide for replacing the default html pages with your own custom files
-* [JWT Token](https://github.com/leeif/pluto/blob/master/docs/jwt.md) gives an introduction of the JWT design in Pluto.
+* [API Document](https://github.com/MuShare/pluto/blob/master/docs/api.md)
+* [Oauth2](https://github.com/MuShare/pluto/blob/master/docs/oauth.md)
+* [Configuration](https://github.com/MuShare/pluto/blob/master/docs/configuration.md)
+* [Replace Views](https://github.com/MuShare/pluto/blob/master/docs/view.md) is a guide for replacing the default html pages with your own custom files
+* [JWT Token](https://github.com/MuShare/pluto/blob/master/docs/jwt.md) gives an introduction of the JWT design in Pluto.
## Contribute
@@ -36,4 +36,4 @@ Feel free to fire an issue or send a pull request.
## License
-MIT License, see [LICENSE](https://github.com/leeif/pluto/blob/master/LICENSE)
+MIT License, see [LICENSE](https://github.com/MuShare/pluto/blob/master/LICENSE)
diff --git a/VERSION b/VERSION
index 1b0c03e..64c411b 100644
--- a/VERSION
+++ b/VERSION
@@ -1 +1 @@
-v1.3.3
\ No newline at end of file
+v1.4
\ No newline at end of file
diff --git a/cmd/pluto-migrate/main.go b/cmd/pluto-migrate/main.go
index 36939ce..b9e3c48 100644
--- a/cmd/pluto-migrate/main.go
+++ b/cmd/pluto-migrate/main.go
@@ -4,12 +4,12 @@ import (
"log"
"os"
- "github.com/leeif/pluto/config"
+ "github.com/MuShare/pluto/config"
- "github.com/leeif/pluto/database"
+ "github.com/MuShare/pluto/database"
_ "github.com/go-sql-driver/mysql"
- "github.com/leeif/pluto/utils/migrate"
+ "github.com/MuShare/pluto/utils/migrate"
)
func main() {
diff --git a/cmd/pluto-server/main.go b/cmd/pluto-server/main.go
index 8a4406b..8dd7173 100644
--- a/cmd/pluto-server/main.go
+++ b/cmd/pluto-server/main.go
@@ -8,23 +8,23 @@ import (
"os/signal"
"time"
- "github.com/leeif/pluto/manage"
- "github.com/leeif/pluto/utils/admin"
+ "github.com/MuShare/pluto/manage"
+ "github.com/MuShare/pluto/utils/admin"
- "github.com/leeif/pluto/server"
+ "github.com/MuShare/pluto/server"
- plog "github.com/leeif/pluto/log"
- "github.com/leeif/pluto/route"
+ plog "github.com/MuShare/pluto/log"
+ "github.com/MuShare/pluto/route"
- "github.com/leeif/pluto/config"
+ "github.com/MuShare/pluto/config"
"go.uber.org/fx"
- "github.com/leeif/pluto/database"
+ "github.com/MuShare/pluto/database"
_ "github.com/go-sql-driver/mysql"
- perror "github.com/leeif/pluto/datatype/pluto_error"
- "github.com/leeif/pluto/utils/rsa"
- "github.com/leeif/pluto/utils/view"
+ perror "github.com/MuShare/pluto/datatype/pluto_error"
+ "github.com/MuShare/pluto/utils/rsa"
+ "github.com/MuShare/pluto/utils/view"
)
// VERSION is the pluto build version
diff --git a/config/config_test.go b/config/config_test.go
index 6230749..6489bd6 100644
--- a/config/config_test.go
+++ b/config/config_test.go
@@ -4,7 +4,7 @@ import (
"os"
"testing"
- "github.com/leeif/pluto/config"
+ "github.com/MuShare/pluto/config"
"github.com/stretchr/testify/assert"
)
diff --git a/database/database.go b/database/database.go
index 659b339..ffade82 100644
--- a/database/database.go
+++ b/database/database.go
@@ -6,7 +6,7 @@ import (
"database/sql"
"fmt"
- "github.com/leeif/pluto/config"
+ "github.com/MuShare/pluto/config"
)
func NewDatabase(config *config.Config) (*sql.DB, error) {
diff --git a/docs/configuration.md b/docs/configuration.md
index f053235..cdf787f 100644
--- a/docs/configuration.md
+++ b/docs/configuration.md
@@ -94,7 +94,7 @@ Expiration time of JWT can be configured.
View template location which Pluto used like register verfication mail or reset password page.
-You can also replace the default pages with your own pages, see [docs/view.md](https://github.com/leeif/pluto/blob/master/docs/view.md) for more information.
+You can also replace the default pages with your own pages, see [docs/view.md](https://github.com/MuShare/pluto/blob/master/docs/view.md) for more information.
| Command line flag | Description | Type | Default |
| ---- | ---- | ---- | ---- |
diff --git a/docs/installation.md b/docs/installation.md
index 76a25cb..ae491bf 100644
--- a/docs/installation.md
+++ b/docs/installation.md
@@ -5,7 +5,7 @@
Pluto provides a database migration tool to create database tables.
```
-git clone https://github.com/leeif/pluto.git
+git clone https://github.com/MuShare/pluto.git
cd pluto/
make migrate-binary-build
@@ -19,7 +19,7 @@ Requirement: Go (> 1.13)
Download the source file.
```
-git clone https://github.com/leeif/pluto.git
+git clone https://github.com/MuShare/pluto.git
cd pluto/
make server-binary-build
./bin/pluto-server --config.file=config.yaml
@@ -27,16 +27,16 @@ make server-binary-build
## Run Pluto with Docker image
```
-docker run -v ${PWD}/config.json:/etc/pluto/config.json --name pluto -d leeif/pluto:latest
+docker run -v ${PWD}/config.json:/etc/pluto/config.json --name pluto -d mushare/pluto:latest
docker logs pluto
```
The default config file location in Pluto container is /etc/pluto/config.json.
-Here we mount a local config file into container. About config, please see here [Configuration](https://github.com/leeif/pluto/blob/master/docs/configuration.md) for more information.
+Here we mount a local config file into container. About config, please see here [Configuration](https://github.com/MuShare/pluto/blob/master/docs/configuration.md) for more information.
Pluto also support several other formats of config file like YAML, TOML.
To use these kinds , you need to pass an env variable like this,
```
-docker run --env ConfigFile=/etc/pluto/config.yaml -v ${PWD}/config.yaml:/etc/pluto/config.yaml --name pluto -d leeif/pluto:latest
+docker run --env ConfigFile=/etc/pluto/config.yaml -v ${PWD}/config.yaml:/etc/pluto/config.yaml --name pluto -d mushare/pluto:latest
```
## Run Pluto in Kubernetes
@@ -63,7 +63,7 @@ spec:
spec:
containers:
- name: pluto
- image: leeif/pluto:latest
+ image: mushare/pluto:latest
volumeMounts:
- name: config-volume
mountPath: /etc/pluto/config.json
diff --git a/docs/jwt.md b/docs/jwt.md
index 00bb943..b7a1d06 100644
--- a/docs/jwt.md
+++ b/docs/jwt.md
@@ -23,20 +23,20 @@ Pluto assign a JWT for each user and you can use this JWT to authenticate users
[signature]
```
-Here is the example of an access JWT token. You can customize the expiration time through [Configuration](https://github.com/leeif/pluto/blob/master/README.md).
+Here is the example of an access JWT token. You can customize the expiration time through [Configuration](https://github.com/MuShare/pluto/blob/master/README.md).
## Signature
### rsa algorithm
-The third part of the JWT token is a signature signed with the rsa private key which provided through [rsa config](https://github.com/leeif/pluto/blob/master/docs/configuration.md#rsa)
+The third part of the JWT token is a signature signed with the rsa private key which provided through [rsa config](https://github.com/MuShare/pluto/blob/master/docs/configuration.md#rsa)
The sign text is a concat of head and payload of a JWT.
```
sign(string(head)+string(payload), )
```
-Verify a signature need the rsa public key, which you can get through the [public key api](https://github.com/leeif/pluto/blob/master/docs/api.md#apiauthpublickey)
+Verify a signature need the rsa public key, which you can get through the [public key api](https://github.com/MuShare/pluto/blob/master/docs/api.md#apiauthpublickey)
```
verify(string(head)+string(payload), )
diff --git a/docs/view.md b/docs/view.md
index 646ec35..a880ea7 100644
--- a/docs/view.md
+++ b/docs/view.md
@@ -1,6 +1,6 @@
# view
Pluto is using the golang [template](https://golang.org/pkg/text/template/) engine to parse the template HTML files.
-Pluto default uses the templates in [views](https://github.com/leeif/pluto/blob/master/views).
+Pluto default uses the templates in [views](https://github.com/MuShare/pluto/blob/master/views).
## template/
@@ -54,6 +54,6 @@ Error
# Replace the default views
Docker
```
-docker run -v ./config.json:/etc/pluto/config.json -v ./views:/views --name pluto -d leeif/pluto:latest
+docker run -v ./config.json:/etc/pluto/config.json -v ./views:/views --name pluto -d mushare/pluto:latest
```
-Replace the default views in container, remember the name of your files should be the same as above except the files under the [views/template/](https://github.com/leeif/pluto/blob/master/views/template/).
\ No newline at end of file
+Replace the default views in container, remember the name of your files should be the same as above except the files under the [views/template/](https://github.com/MuShare/pluto/blob/master/views/template/).
\ No newline at end of file
diff --git a/go.mod b/go.mod
index e572f26..1e93ec1 100644
--- a/go.mod
+++ b/go.mod
@@ -1,4 +1,4 @@
-module github.com/leeif/pluto
+module github.com/MuShare/pluto
go 1.12
@@ -10,19 +10,15 @@ require (
github.com/aliyun/aliyun-oss-go-sdk v2.0.2+incompatible
github.com/dgrijalva/jwt-go v3.2.0+incompatible
github.com/friendsofgo/errors v0.9.2
- github.com/go-acme/lego/v3 v3.1.0
github.com/go-kit/kit v0.9.0
github.com/go-sql-driver/mysql v1.4.1
github.com/gorilla/context v1.1.1
github.com/gorilla/mux v1.7.3
github.com/gorilla/schema v1.1.0
- github.com/gorilla/sessions v1.2.0
github.com/leeif/kiper v0.3.0
github.com/micro/go-micro v1.18.0
github.com/micro/go-plugins/registry/consul v0.0.0-20200119172437-4fe21aa238fd
github.com/micro/go-plugins/server/http v0.0.0-20200119172437-4fe21aa238fd
- github.com/pelletier/go-toml v1.2.0
- github.com/prometheus/common v0.6.0
github.com/rs/cors v1.7.0
github.com/stretchr/testify v1.4.0
github.com/urfave/negroni v1.0.0
diff --git a/go.sum b/go.sum
index 690024f..6c07e0c 100644
--- a/go.sum
+++ b/go.sum
@@ -216,10 +216,6 @@ github.com/gorilla/mux v1.7.3 h1:gnP5JzjVOuiZD07fKKToCAOjS0yOpj/qPETTXCCS6hw=
github.com/gorilla/mux v1.7.3/go.mod h1:1lud6UwP+6orDFRuTfBEV8e9/aOM/c4fVVCaMa2zaAs=
github.com/gorilla/schema v1.1.0 h1:CamqUDOFUBqzrvxuz2vEwo8+SUdwsluFh7IlzJh30LY=
github.com/gorilla/schema v1.1.0/go.mod h1:kgLaKoK1FELgZqMAVxx/5cbj0kT+57qxUrAlIO2eleU=
-github.com/gorilla/securecookie v1.1.1 h1:miw7JPhV+b/lAHSXz4qd/nN9jRiAFV5FwjeKyCS8BvQ=
-github.com/gorilla/securecookie v1.1.1/go.mod h1:ra0sb63/xPlUeL+yeDciTfxMRAA+MP+HVt/4epWDjd4=
-github.com/gorilla/sessions v1.2.0 h1:S7P+1Hm5V/AT9cjEcUD5uDaQSX0OE577aCXgoaKpYbQ=
-github.com/gorilla/sessions v1.2.0/go.mod h1:dk2InVEVJ0sfLlnXv9EAgkf6ecYs/i80K/zI+bUmuGM=
github.com/gorilla/websocket v1.2.0/go.mod h1:E7qHFY5m1UJ88s3WnNqhKjPHQ0heANvMoAMk2YaljkQ=
github.com/gorilla/websocket v1.4.0/go.mod h1:E7qHFY5m1UJ88s3WnNqhKjPHQ0heANvMoAMk2YaljkQ=
github.com/gorilla/websocket v1.4.1 h1:q7AeDBpnBk8AogcD4DSag/Ukw/KV+YhzLj2bP5HvKCM=
diff --git a/log/log.go b/log/log.go
index 002e0eb..83c3b25 100644
--- a/log/log.go
+++ b/log/log.go
@@ -6,7 +6,7 @@ import (
"github.com/go-kit/kit/log"
"github.com/go-kit/kit/log/level"
- "github.com/leeif/pluto/config"
+ "github.com/MuShare/pluto/config"
)
type PlutoLog struct {
diff --git a/manage/admin.go b/manage/admin.go
index 0490cee..8f0ea89 100644
--- a/manage/admin.go
+++ b/manage/admin.go
@@ -3,11 +3,11 @@ package manage
import (
"database/sql"
- "github.com/leeif/pluto/modelexts"
+ "github.com/MuShare/pluto/modelexts"
- perror "github.com/leeif/pluto/datatype/pluto_error"
- "github.com/leeif/pluto/datatype/request"
- "github.com/leeif/pluto/models"
+ perror "github.com/MuShare/pluto/datatype/pluto_error"
+ "github.com/MuShare/pluto/datatype/request"
+ "github.com/MuShare/pluto/models"
"github.com/volatiletech/sqlboiler/boil"
"github.com/volatiletech/sqlboiler/queries/qm"
)
diff --git a/manage/oauth.go b/manage/oauth.go
index 6a31372..5465a1f 100644
--- a/manage/oauth.go
+++ b/manage/oauth.go
@@ -8,15 +8,15 @@ import (
"time"
"github.com/RichardKnop/uuid"
- "github.com/leeif/pluto/datatype/pluto_error"
- perror "github.com/leeif/pluto/datatype/pluto_error"
- "github.com/leeif/pluto/datatype/request"
- "github.com/leeif/pluto/modelexts"
- "github.com/leeif/pluto/models"
- "github.com/leeif/pluto/utils/general"
- "github.com/leeif/pluto/utils/jwt"
- "github.com/leeif/pluto/utils/refresh"
- saltUtil "github.com/leeif/pluto/utils/salt"
+ "github.com/MuShare/pluto/datatype/pluto_error"
+ perror "github.com/MuShare/pluto/datatype/pluto_error"
+ "github.com/MuShare/pluto/datatype/request"
+ "github.com/MuShare/pluto/modelexts"
+ "github.com/MuShare/pluto/models"
+ "github.com/MuShare/pluto/utils/general"
+ "github.com/MuShare/pluto/utils/jwt"
+ "github.com/MuShare/pluto/utils/refresh"
+ saltUtil "github.com/MuShare/pluto/utils/salt"
"github.com/volatiletech/sqlboiler/boil"
"github.com/volatiletech/sqlboiler/queries/qm"
"github.com/wxnacy/wgo/arrays"
diff --git a/manage/token.go b/manage/token.go
index 484c571..601c24e 100644
--- a/manage/token.go
+++ b/manage/token.go
@@ -4,10 +4,10 @@ import (
"database/sql"
"time"
- perror "github.com/leeif/pluto/datatype/pluto_error"
- "github.com/leeif/pluto/datatype/request"
- "github.com/leeif/pluto/models"
- "github.com/leeif/pluto/utils/jwt"
+ perror "github.com/MuShare/pluto/datatype/pluto_error"
+ "github.com/MuShare/pluto/datatype/request"
+ "github.com/MuShare/pluto/models"
+ "github.com/MuShare/pluto/utils/jwt"
"github.com/volatiletech/sqlboiler/queries/qm"
)
diff --git a/manage/user.go b/manage/user.go
index 54cbbb5..a410ed9 100644
--- a/manage/user.go
+++ b/manage/user.go
@@ -18,16 +18,16 @@ import (
"github.com/volatiletech/sqlboiler/queries/qm"
- "github.com/leeif/pluto/config"
- "github.com/leeif/pluto/modelexts"
+ "github.com/MuShare/pluto/config"
+ "github.com/MuShare/pluto/modelexts"
gjwt "github.com/dgrijalva/jwt-go"
- perror "github.com/leeif/pluto/datatype/pluto_error"
- "github.com/leeif/pluto/datatype/request"
- "github.com/leeif/pluto/models"
- "github.com/leeif/pluto/utils/avatar"
- "github.com/leeif/pluto/utils/jwt"
- saltUtil "github.com/leeif/pluto/utils/salt"
+ perror "github.com/MuShare/pluto/datatype/pluto_error"
+ "github.com/MuShare/pluto/datatype/request"
+ "github.com/MuShare/pluto/models"
+ "github.com/MuShare/pluto/utils/avatar"
+ "github.com/MuShare/pluto/utils/jwt"
+ saltUtil "github.com/MuShare/pluto/utils/salt"
"google.golang.org/api/oauth2/v2"
)
diff --git a/manage/utils.go b/manage/utils.go
index 7f37f13..1ef7a39 100644
--- a/manage/utils.go
+++ b/manage/utils.go
@@ -7,11 +7,11 @@ import (
"github.com/volatiletech/sqlboiler/boil"
"github.com/wxnacy/wgo/arrays"
- "github.com/leeif/pluto/config"
- perror "github.com/leeif/pluto/datatype/pluto_error"
- "github.com/leeif/pluto/log"
- plog "github.com/leeif/pluto/log"
- "github.com/leeif/pluto/models"
+ "github.com/MuShare/pluto/config"
+ perror "github.com/MuShare/pluto/datatype/pluto_error"
+ "github.com/MuShare/pluto/log"
+ plog "github.com/MuShare/pluto/log"
+ "github.com/MuShare/pluto/models"
"github.com/volatiletech/sqlboiler/queries/qm"
)
diff --git a/middleware/pluto.go b/middleware/pluto.go
index 837fb59..50a3815 100644
--- a/middleware/pluto.go
+++ b/middleware/pluto.go
@@ -4,11 +4,11 @@ import (
"net/http"
"time"
- "github.com/leeif/pluto/utils/general"
+ "github.com/MuShare/pluto/utils/general"
"github.com/gorilla/context"
- perror "github.com/leeif/pluto/datatype/pluto_error"
- "github.com/leeif/pluto/utils/jwt"
+ perror "github.com/MuShare/pluto/datatype/pluto_error"
+ "github.com/MuShare/pluto/utils/jwt"
"github.com/wxnacy/wgo/arrays"
)
diff --git a/middleware/token.go b/middleware/token.go
index 03aef4b..5d06616 100644
--- a/middleware/token.go
+++ b/middleware/token.go
@@ -5,8 +5,8 @@ import (
"time"
"github.com/gorilla/context"
- perror "github.com/leeif/pluto/datatype/pluto_error"
- "github.com/leeif/pluto/utils/jwt"
+ perror "github.com/MuShare/pluto/datatype/pluto_error"
+ "github.com/MuShare/pluto/utils/jwt"
)
func AccessTokenAuth(w http.ResponseWriter, r *http.Request) *perror.PlutoError {
diff --git a/middleware/utils.go b/middleware/utils.go
index 4b7f3b7..456337d 100644
--- a/middleware/utils.go
+++ b/middleware/utils.go
@@ -4,7 +4,7 @@ import (
"net/http"
"strings"
- perror "github.com/leeif/pluto/datatype/pluto_error"
+ perror "github.com/MuShare/pluto/datatype/pluto_error"
"github.com/urfave/negroni"
)
diff --git a/modelexts/exts.go b/modelexts/exts.go
index 8164832..0217b61 100644
--- a/modelexts/exts.go
+++ b/modelexts/exts.go
@@ -1,6 +1,6 @@
package modelexts
-import "github.com/leeif/pluto/models"
+import "github.com/MuShare/pluto/models"
type User struct {
User *models.User
diff --git a/route/routes.go b/route/routes.go
index 875fa0a..c4c16d7 100644
--- a/route/routes.go
+++ b/route/routes.go
@@ -4,15 +4,15 @@ import (
"net/http"
"strings"
- "github.com/leeif/pluto/config"
- "github.com/leeif/pluto/middleware"
- v1 "github.com/leeif/pluto/route/v1"
+ "github.com/MuShare/pluto/config"
+ "github.com/MuShare/pluto/middleware"
+ v1 "github.com/MuShare/pluto/route/v1"
"github.com/gorilla/mux"
- perror "github.com/leeif/pluto/datatype/pluto_error"
- "github.com/leeif/pluto/log"
- "github.com/leeif/pluto/manage"
- routeUtils "github.com/leeif/pluto/utils/route"
+ perror "github.com/MuShare/pluto/datatype/pluto_error"
+ "github.com/MuShare/pluto/log"
+ "github.com/MuShare/pluto/manage"
+ routeUtils "github.com/MuShare/pluto/utils/route"
)
type middle func(handlerWrapper middleware.HandlerWrapper, handlers ...func(http.ResponseWriter, *http.Request) *perror.PlutoError) http.Handler
diff --git a/route/utils.go b/route/utils.go
index 166606a..da19bf0 100644
--- a/route/utils.go
+++ b/route/utils.go
@@ -8,9 +8,9 @@ import (
"github.com/urfave/negroni"
- routeUtils "github.com/leeif/pluto/utils/route"
+ routeUtils "github.com/MuShare/pluto/utils/route"
- perror "github.com/leeif/pluto/datatype/pluto_error"
+ perror "github.com/MuShare/pluto/datatype/pluto_error"
)
func (router *Router) plutoHandlerWrapper(handler func(http.ResponseWriter, *http.Request) *perror.PlutoError) negroni.HandlerFunc {
diff --git a/route/v1.go b/route/v1.go
index e04da0c..cf2d2cb 100644
--- a/route/v1.go
+++ b/route/v1.go
@@ -3,7 +3,7 @@ package route
import (
"path"
- "github.com/leeif/pluto/middleware"
+ "github.com/MuShare/pluto/middleware"
)
func (r *Router) registerUserV1Routes(prefix string) {
diff --git a/route/v1/admin.go b/route/v1/admin.go
index e8b96fb..0060c6d 100644
--- a/route/v1/admin.go
+++ b/route/v1/admin.go
@@ -3,10 +3,10 @@ package v1
import (
"net/http"
- perror "github.com/leeif/pluto/datatype/pluto_error"
+ perror "github.com/MuShare/pluto/datatype/pluto_error"
- "github.com/leeif/pluto/datatype/request"
- routeUtils "github.com/leeif/pluto/utils/route"
+ "github.com/MuShare/pluto/datatype/request"
+ routeUtils "github.com/MuShare/pluto/utils/route"
)
func (router *Router) CreateRole(w http.ResponseWriter, r *http.Request) *perror.PlutoError {
diff --git a/route/v1/health.go b/route/v1/health.go
index 4cdcb4d..d6ba304 100644
--- a/route/v1/health.go
+++ b/route/v1/health.go
@@ -3,8 +3,8 @@ package v1
import (
"net/http"
- perror "github.com/leeif/pluto/datatype/pluto_error"
- routeUtils "github.com/leeif/pluto/utils/route"
+ perror "github.com/MuShare/pluto/datatype/pluto_error"
+ routeUtils "github.com/MuShare/pluto/utils/route"
)
func (router *Router) HealthCheck(w http.ResponseWriter, r *http.Request) *perror.PlutoError {
diff --git a/route/v1/oauth.go b/route/v1/oauth.go
index eb8f14a..974b2fa 100644
--- a/route/v1/oauth.go
+++ b/route/v1/oauth.go
@@ -7,11 +7,11 @@ import (
"path"
"time"
- perror "github.com/leeif/pluto/datatype/pluto_error"
- "github.com/leeif/pluto/datatype/request"
- "github.com/leeif/pluto/manage"
- "github.com/leeif/pluto/utils/general"
- routeUtils "github.com/leeif/pluto/utils/route"
+ perror "github.com/MuShare/pluto/datatype/pluto_error"
+ "github.com/MuShare/pluto/datatype/request"
+ "github.com/MuShare/pluto/manage"
+ "github.com/MuShare/pluto/utils/general"
+ routeUtils "github.com/MuShare/pluto/utils/route"
)
func (router *Router) fetchClient(r *http.Request) (string, string, *perror.PlutoError) {
diff --git a/route/v1/token.go b/route/v1/token.go
index 07f923d..0e89660 100644
--- a/route/v1/token.go
+++ b/route/v1/token.go
@@ -3,10 +3,10 @@ package v1
import (
"net/http"
- perror "github.com/leeif/pluto/datatype/pluto_error"
- "github.com/leeif/pluto/datatype/request"
- routeUtils "github.com/leeif/pluto/utils/route"
- "github.com/leeif/pluto/utils/rsa"
+ perror "github.com/MuShare/pluto/datatype/pluto_error"
+ "github.com/MuShare/pluto/datatype/request"
+ routeUtils "github.com/MuShare/pluto/utils/route"
+ "github.com/MuShare/pluto/utils/rsa"
)
func (router *Router) RefreshToken(w http.ResponseWriter, r *http.Request) *perror.PlutoError {
diff --git a/route/v1/user.go b/route/v1/user.go
index 552da55..190a3be 100644
--- a/route/v1/user.go
+++ b/route/v1/user.go
@@ -3,12 +3,12 @@ package v1
import (
"net/http"
- perror "github.com/leeif/pluto/datatype/pluto_error"
- "github.com/leeif/pluto/datatype/request"
- "github.com/leeif/pluto/manage"
- "github.com/leeif/pluto/utils/general"
- "github.com/leeif/pluto/utils/mail"
- routeUtils "github.com/leeif/pluto/utils/route"
+ perror "github.com/MuShare/pluto/datatype/pluto_error"
+ "github.com/MuShare/pluto/datatype/request"
+ "github.com/MuShare/pluto/manage"
+ "github.com/MuShare/pluto/utils/general"
+ "github.com/MuShare/pluto/utils/mail"
+ routeUtils "github.com/MuShare/pluto/utils/route"
)
func (router *Router) Login(w http.ResponseWriter, r *http.Request) *perror.PlutoError {
diff --git a/route/v1/utils.go b/route/v1/utils.go
index e45adb0..1b80dd0 100644
--- a/route/v1/utils.go
+++ b/route/v1/utils.go
@@ -1,9 +1,9 @@
package v1
import (
- "github.com/leeif/pluto/config"
- "github.com/leeif/pluto/log"
- "github.com/leeif/pluto/manage"
+ "github.com/MuShare/pluto/config"
+ "github.com/MuShare/pluto/log"
+ "github.com/MuShare/pluto/manage"
)
type Router struct {
diff --git a/route/v1/web.go b/route/v1/web.go
index ccea1f9..c61d706 100644
--- a/route/v1/web.go
+++ b/route/v1/web.go
@@ -4,10 +4,10 @@ import (
"net/http"
"github.com/gorilla/mux"
- perror "github.com/leeif/pluto/datatype/pluto_error"
- "github.com/leeif/pluto/datatype/request"
- "github.com/leeif/pluto/utils/general"
- routeUtils "github.com/leeif/pluto/utils/route"
+ perror "github.com/MuShare/pluto/datatype/pluto_error"
+ "github.com/MuShare/pluto/datatype/request"
+ "github.com/MuShare/pluto/utils/general"
+ routeUtils "github.com/MuShare/pluto/utils/route"
)
func (router *Router) RegistrationVerifyPage(w http.ResponseWriter, r *http.Request) *perror.PlutoError {
diff --git a/server/server.go b/server/server.go
index 04f330c..6b19620 100644
--- a/server/server.go
+++ b/server/server.go
@@ -16,7 +16,7 @@ import (
"github.com/rs/cors"
"go.uber.org/fx"
- "github.com/leeif/pluto/config"
+ "github.com/MuShare/pluto/config"
httpServer "github.com/micro/go-plugins/server/http"
)
diff --git a/utils/admin/admin.go b/utils/admin/admin.go
index 7314839..72d900f 100644
--- a/utils/admin/admin.go
+++ b/utils/admin/admin.go
@@ -5,17 +5,17 @@ import (
"fmt"
"log"
- "github.com/leeif/pluto/utils/general"
- "github.com/leeif/pluto/utils/mail"
- "github.com/leeif/pluto/utils/salt"
+ "github.com/MuShare/pluto/utils/general"
+ "github.com/MuShare/pluto/utils/mail"
+ "github.com/MuShare/pluto/utils/salt"
- "github.com/leeif/pluto/datatype/request"
+ "github.com/MuShare/pluto/datatype/request"
- perror "github.com/leeif/pluto/datatype/pluto_error"
- "github.com/leeif/pluto/manage"
+ perror "github.com/MuShare/pluto/datatype/pluto_error"
+ "github.com/MuShare/pluto/manage"
- "github.com/leeif/pluto/config"
- plog "github.com/leeif/pluto/log"
+ "github.com/MuShare/pluto/config"
+ plog "github.com/MuShare/pluto/log"
)
func Init(db *sql.DB, config *config.Config) *perror.PlutoError {
diff --git a/utils/avatar/avatar.go b/utils/avatar/avatar.go
index 85730e5..1bc1fd8 100644
--- a/utils/avatar/avatar.go
+++ b/utils/avatar/avatar.go
@@ -13,8 +13,8 @@ import (
b64 "encoding/base64"
"github.com/aliyun/aliyun-oss-go-sdk/oss"
- "github.com/leeif/pluto/config"
- perror "github.com/leeif/pluto/datatype/pluto_error"
+ "github.com/MuShare/pluto/config"
+ perror "github.com/MuShare/pluto/datatype/pluto_error"
)
var validAvatarType = []string{"jpeg", "jpg", "png"}
diff --git a/utils/avatar/avatar_test.go b/utils/avatar/avatar_test.go
index 8c997db..52c3a2b 100644
--- a/utils/avatar/avatar_test.go
+++ b/utils/avatar/avatar_test.go
@@ -4,7 +4,7 @@ import (
"fmt"
"testing"
- "github.com/leeif/pluto/utils/avatar"
+ "github.com/MuShare/pluto/utils/avatar"
"github.com/stretchr/testify/assert"
)
diff --git a/utils/jwt/jwt.go b/utils/jwt/jwt.go
index f36322b..c725a65 100644
--- a/utils/jwt/jwt.go
+++ b/utils/jwt/jwt.go
@@ -8,9 +8,9 @@ import (
"strings"
"time"
- perror "github.com/leeif/pluto/datatype/pluto_error"
+ perror "github.com/MuShare/pluto/datatype/pluto_error"
- "github.com/leeif/pluto/utils/rsa"
+ "github.com/MuShare/pluto/utils/rsa"
)
const (
diff --git a/utils/mail/mail.go b/utils/mail/mail.go
index 4cea486..8a1eea6 100644
--- a/utils/mail/mail.go
+++ b/utils/mail/mail.go
@@ -9,12 +9,12 @@ import (
"net/mail"
"net/smtp"
- "github.com/leeif/pluto/utils/view"
+ "github.com/MuShare/pluto/utils/view"
- "github.com/leeif/pluto/config"
- "github.com/leeif/pluto/utils/jwt"
+ "github.com/MuShare/pluto/config"
+ "github.com/MuShare/pluto/utils/jwt"
- perror "github.com/leeif/pluto/datatype/pluto_error"
+ perror "github.com/MuShare/pluto/datatype/pluto_error"
)
type Mail struct {
diff --git a/utils/route/route.go b/utils/route/route.go
index d390114..1ba15b8 100644
--- a/utils/route/route.go
+++ b/utils/route/route.go
@@ -14,12 +14,12 @@ import (
"github.com/gorilla/schema"
"github.com/wxnacy/wgo/arrays"
- perror "github.com/leeif/pluto/datatype/pluto_error"
- "github.com/leeif/pluto/datatype/request"
- resp "github.com/leeif/pluto/datatype/response"
- "github.com/leeif/pluto/log"
- "github.com/leeif/pluto/utils/jwt"
- "github.com/leeif/pluto/utils/view"
+ perror "github.com/MuShare/pluto/datatype/pluto_error"
+ "github.com/MuShare/pluto/datatype/request"
+ resp "github.com/MuShare/pluto/datatype/response"
+ "github.com/MuShare/pluto/log"
+ "github.com/MuShare/pluto/utils/jwt"
+ "github.com/MuShare/pluto/utils/view"
)
func GetBaseURL(r *http.Request) string {
diff --git a/utils/rsa/rsa.go b/utils/rsa/rsa.go
index 02c1671..a1dbf31 100644
--- a/utils/rsa/rsa.go
+++ b/utils/rsa/rsa.go
@@ -13,7 +13,7 @@ import (
"log"
- "github.com/leeif/pluto/config"
+ "github.com/MuShare/pluto/config"
)
var (
diff --git a/utils/salt/salt.go b/utils/salt/salt.go
index d74f0f3..8bb69ca 100644
--- a/utils/salt/salt.go
+++ b/utils/salt/salt.go
@@ -5,7 +5,7 @@ import (
"encoding/base64"
"strings"
- perror "github.com/leeif/pluto/datatype/pluto_error"
+ perror "github.com/MuShare/pluto/datatype/pluto_error"
"golang.org/x/crypto/scrypt"
)
diff --git a/utils/view/view.go b/utils/view/view.go
index 2dc052b..f438083 100644
--- a/utils/view/view.go
+++ b/utils/view/view.go
@@ -10,7 +10,7 @@ import (
"regexp"
"github.com/alecthomas/template"
- "github.com/leeif/pluto/config"
+ "github.com/MuShare/pluto/config"
"golang.org/x/text/language"
)
diff --git a/utils/view/view_test.go b/utils/view/view_test.go
index b5ef871..df971c9 100644
--- a/utils/view/view_test.go
+++ b/utils/view/view_test.go
@@ -3,8 +3,8 @@ package view_test
import (
"testing"
- "github.com/leeif/pluto/config"
- "github.com/leeif/pluto/utils/view"
+ "github.com/MuShare/pluto/config"
+ "github.com/MuShare/pluto/utils/view"
"github.com/stretchr/testify/assert"
)
diff --git a/views/en/password_reset_mail.html b/views/en/password_reset_mail.html
index 67fef01..6d8cb23 100644
--- a/views/en/password_reset_mail.html
+++ b/views/en/password_reset_mail.html
@@ -21,13 +21,13 @@ We send this mai
sent a request for resetting your password of Pluto login service.
You can reset your password by clicking this
button within 10 minutes.
- Reset
Password
If you cannot open it, please copy this link
and open it in your browser:
- {{.BaseURL}}/password/reset/{{.Token}}
+ https://{{.BaseURL}}/web/password/reset/{{.Token}}
If you did not send such request, just
ignore this mail.
Sincerely yours,
@@ -38,7 +38,7 @@ Pluto
text-align: center;
display: block;
text-decoration: none;
- font-size: 13px">Powered by Pluto.
+ font-size: 13px">Powered by Pluto.