Skip to content

Commit

Permalink
Add UI boilerplate with sign up, sign in and ability to list clusters (
Browse files Browse the repository at this point in the history
  • Loading branch information
jmorganca committed Jul 30, 2021
1 parent dbef0e1 commit 23cccd3
Show file tree
Hide file tree
Showing 49 changed files with 9,900 additions and 478 deletions.
2 changes: 1 addition & 1 deletion .dockerignore
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ gon.json
Makefile
Dockerfile
build
internal/ui
internal/registry/ui
.test
.vscode
dist
2 changes: 2 additions & 0 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,8 @@ proto:
--validate_out="lang=go:./internal/v1" --validate_opt paths=source_relative \
--go_out ./internal/v1 --go_opt paths=source_relative \
--go-grpc_out ./internal/v1 --go-grpc_opt paths=source_relative \
--grpc-gateway_out ./internal/v1 --grpc-gateway_opt logtostderr=true --grpc-gateway_opt paths=source_relative --grpc-gateway_opt generate_unbound_methods=true \
--grpc-gateway-ts_out=./internal/registry/ui/gen \
./internal/v1/*.proto

.PHONY: build
Expand Down
6 changes: 0 additions & 6 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -25,12 +25,6 @@ helm repo add infrahq https://helm.infrahq.com
helm install infra infrahq/infra
```

Infra exposes an **external IP** address via a load balanacer. To list services and check which IP address is exposed, run:

```
kubectl get svc infra
```

### Install Infra CLI

**macOS & Linux**
Expand Down
20 changes: 20 additions & 0 deletions docs/contributing.md
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,26 @@ Run a full setup (Infra Registry + Infra Engine):
make dev
```

## Working on the UI

Developing the UI requires two tabs:

```
# In first terminal window, run next.js dev server
cd internal/registry/ui
npm install
npm run dev
# In second terminal window, run Go server
go run . registry --ui-proxy=http://localhost:3000
```

To build a static version of the ui that can be imported into the Go server:

```
make generate
```

## Generate docs

```
Expand Down
28 changes: 12 additions & 16 deletions go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -5,53 +5,49 @@ go 1.16
require (
github.com/AlecAivazis/survey/v2 v2.2.13
github.com/MakeNowJust/heredoc/v2 v2.0.1
github.com/NYTimes/gziphandler v0.0.0-20170623195520-56545f4a5d46
github.com/aws/aws-sdk-go v1.38.35
github.com/cli/browser v1.1.0
github.com/docker/go-units v0.4.0
github.com/elazarl/go-bindata-assetfs v1.0.1
github.com/envoyproxy/protoc-gen-validate v0.6.2-0.20210710165204-c2b08efda458
github.com/go-chi/chi v1.5.4
github.com/go-playground/assert/v2 v2.0.1
github.com/golang/protobuf v1.5.2
github.com/google/go-cmp v0.5.6 // indirect
github.com/google/go-github/v25 v25.0.1 // indirect
github.com/google/gofuzz v1.2.0 // indirect
github.com/google/shlex v0.0.0-20191202100458-e7afc7fbc510
github.com/googleapis/gnostic v0.5.5 // indirect
github.com/goreleaser/goreleaser v0.173.2 // indirect
github.com/goreleaser/nfpm v0.11.0 // indirect
github.com/goreleaser/goreleaser v0.173.2
github.com/gorilla/handlers v1.5.1
github.com/goware/urlx v0.3.1
github.com/grpc-ecosystem/go-grpc-middleware v1.3.0
github.com/imdario/mergo v0.3.12 // indirect
github.com/grpc-ecosystem/grpc-gateway/v2 v2.5.0
github.com/grpc-ecosystem/protoc-gen-grpc-gateway-ts v1.1.1
github.com/hashicorp/go-hclog v0.9.3-0.20191025211905-234833755cb2 // indirect
github.com/jessevdk/go-flags v1.5.0
github.com/json-iterator/go v1.1.11 // indirect
github.com/kamilsk/retry/v4 v4.0.0 // indirect
github.com/kevinburke/go-bindata v3.22.0+incompatible
github.com/mattn/go-colorable v0.1.8 // indirect
github.com/mattn/go-isatty v0.0.13 // indirect
github.com/mattn/go-runewidth v0.0.12 // indirect
github.com/mattn/go-zglob v0.0.0-20180803001819-2ea3427bfa53 // indirect
github.com/mitchellh/go-homedir v1.1.0
github.com/mitchellh/gon v0.2.3
github.com/muesli/termenv v0.8.1
github.com/natefinch/lumberjack v2.0.0+incompatible
github.com/okta/okta-sdk-golang/v2 v2.3.0
github.com/olekukonko/tablewriter v0.0.5
github.com/rivo/uniseg v0.2.0 // indirect
github.com/sirupsen/logrus v1.8.1
github.com/sirupsen/logrus v1.8.1 // indirect
github.com/spf13/afero v1.6.0
github.com/spf13/cobra v1.2.1
github.com/stretchr/testify v1.7.0
github.com/vektra/mockery/v2 v2.9.0 // indirect
go.uber.org/zap v1.18.1
golang.org/x/crypto v0.0.0-20210506145944-38f3c27a63bf
golang.org/x/net v0.0.0-20210525063256-abc453219eb5
golang.org/x/net v0.0.0-20210525063256-abc453219eb5 // indirect
golang.org/x/oauth2 v0.0.0-20210628180205-a41e5a781914
golang.org/x/sys v0.0.0-20210616094352-59db8d763f22 // indirect
google.golang.org/appengine v1.6.7 // indirect
google.golang.org/genproto v0.0.0-20210630183607-d20f26d13c79 // indirect
google.golang.org/genproto v0.0.0-20210630183607-d20f26d13c79
google.golang.org/grpc v1.38.0
google.golang.org/grpc/cmd/protoc-gen-go-grpc v1.1.0
google.golang.org/protobuf v1.27.1
gopkg.in/check.v1 v1.0.0-20201130134442-10cb98267c6c // indirect
gopkg.in/natefinch/lumberjack.v2 v2.0.0 // indirect
gopkg.in/square/go-jose.v2 v2.5.1
gopkg.in/yaml.v2 v2.4.0
gorm.io/driver/sqlite v1.1.4
Expand Down

0 comments on commit 23cccd3

Please sign in to comment.