Skip to content

Commit

Permalink
Update dependencies
Browse files Browse the repository at this point in the history
  • Loading branch information
ribice committed Jul 11, 2019
1 parent 7c3f94a commit f60654d
Show file tree
Hide file tree
Showing 10 changed files with 32 additions and 25 deletions.
2 changes: 2 additions & 0 deletions .env
@@ -0,0 +1,2 @@
ADMIN_USERNAME=admin
ADMIN_PASSWORD=pass
3 changes: 1 addition & 2 deletions .gitignore
Expand Up @@ -7,5 +7,4 @@
.DS_Store
*-data/
*.test
*.out
*.env
*.out
6 changes: 2 additions & 4 deletions Gopkg.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion README.md
Expand Up @@ -16,7 +16,7 @@ Goch is a fork of [Gossip](https://github.com/aneshas/gossip), with many added f

## Getting started

To run goch locally, you need `docker`, `docker-compose` and `go` installed and set on your path. After downloading/cloning the project, run `./up` which compiles the binary and runs docker-compose with goch, NATS Streaming and Redis. If there were no errors, goch should be running on localhost (port 80).
To run goch locally, you need `docker`, `docker-compose` and `go` installed and set on your path. After downloading/cloning the project, run `./up` which compiles the binary and runs docker-compose with goch, NATS Streaming and Redis. If there were no errors, goch should be running on localhost (port 8080).

## License

Expand Down
4 changes: 2 additions & 2 deletions cmd/goch/main.go
Expand Up @@ -30,8 +30,8 @@ func main() {
store, err := redis.New(cfg.Redis.Address, cfg.Redis.Password, cfg.Redis.Port)
checkErr(err)

srv, mux := msv.New(cfg.Server.Port, "goch")
aMW := bauth.New(cfg.Admin.Username, cfg.Admin.Password)
srv, mux := msv.New("goch")
aMW := bauth.New(cfg.Admin.Username, cfg.Admin.Password, "GOCH")

agent.NewAPI(mux, broker.New(mq, store, ingest.New(mq, store)), store, cfg)
chat.New(mux, store, cfg, aMW.MWFunc)
Expand Down
5 changes: 2 additions & 3 deletions internal/chat/chat.go
Expand Up @@ -8,7 +8,6 @@ import (

"github.com/gorilla/mux"
"github.com/ribice/goch"
"github.com/ribice/msv/bind"
"github.com/ribice/msv/render"
)

Expand Down Expand Up @@ -75,7 +74,7 @@ func (cr *createReq) Bind() error {

func (api *API) createChannel(w http.ResponseWriter, r *http.Request) {
var req createReq
if err := bind.JSON(w, r, &req); err != nil {
if err := render.Bind(w, r, &req); err != nil {
return
}
ch := goch.NewChannel(req.Name, req.IsPrivate)
Expand Down Expand Up @@ -120,7 +119,7 @@ func (r *registerReq) Bind() error {

func (api *API) register(w http.ResponseWriter, r *http.Request) {
var req registerReq
if err := bind.JSON(w, r, &req); err != nil {
if err := render.Bind(w, r, &req); err != nil {
return
}
ch, err := api.store.Get(req.Channel)
Expand Down
10 changes: 6 additions & 4 deletions vendor/github.com/ribice/msv/middleware/bauth/bauth.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 0 additions & 1 deletion vendor/github.com/ribice/msv/middleware/httplog/httplog.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

9 changes: 7 additions & 2 deletions vendor/github.com/ribice/msv/server.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

0 comments on commit f60654d

Please sign in to comment.