Sign inSign up

kuberlab/cloud-dealer

By kuberlab

Updated over 2 years ago

Kibernetika project, backend component

Image
3

10K+

kuberlab/cloud-dealer repository overview

Cloud Dealer

Local start

Get all dependencies:

go mod vendor

Demo API starts with SQLite for data and Redis/Memory for sessions.

BASE_URL=http://localhost:8082 go run cloud-dealer.go

API methods

API version

Current API version is /api/v0.2

Documentation

Open Swagger on http://localhost:8082/docs/apidocs/ and explore http://localhost:8082/docs/apidocs.json.

Unit testing

TESTING=1 go test ./pkg/...

Save app credentials to kubernetes:

kubectl --namespace kuberlab create secret generic app-credentials  --from-file=./bitbucket.json --from-file=./github.json --from-file=./google.json --from-file=./smtp.json --from-file=./admins.json

Local Elasticsearch start:

Current cloud-dealer's version works only with Elasticsearch version 2.X. Start Elasticsearch docker container localy:

docker run -p 9200:9200 -e "http.host=0.0.0.0" -e "transport.host=127.0.0.1" elasticsearch:2.4

Create docker secret

kubectl create secret docker-registry kuberlab-docker --docker-server=https://index.docker.io/v1/ --docker-username=kuberlabdeploy --docker-password=xxxx --docker-email=[email protected]

Go 1.16 support (go mod)

Initialization:

go mod init
go mod vendor

And test:

go run cloud-dealer.go

Tag summary

Content type

Image

Digest

sha256:7de9cd238

Size

278.1 MB

Last updated

over 2 years ago

docker pull kuberlab/cloud-dealer