-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
init commit - cover the old logic and makes this commit as a new base…
…line
- Loading branch information
Showing
34 changed files
with
1,247 additions
and
1,354 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1,4 @@ | ||
/.idea | ||
/.idea | ||
/initconfig/initconfig | ||
/initconfig/*.tgz | ||
/dist |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
IMAGE_TAG_BASE ?= cnosdb/init-config | ||
DIST ?= dist | ||
init-config-build: | ||
GOOS=linux GOARCH=amd64 CGO_ENABLED=0 go build -o $(DIST)/initconfig initconfig/main.go | ||
init-config-image: | ||
cp initconfig/Dockerfile $(DIST)/Dockerfile | ||
cd $(DIST)&&docker build -t $(IMAGE_TAG_BASE):latest . | ||
init-config: init-config-build init-config-image | ||
|
||
helm-package: | ||
cd $(DIST)&&helm package ../charts/cnosdb | ||
|
||
build: init-config helm-package | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,42 +1 @@ | ||
CnosDB can be accessed via port {{ .Values.config.http.bind_address | default 8086 }} on the following DNS name from within your cluster: | ||
|
||
http://{{ include "cnosdb.fullname" . }}.{{ .Release.Namespace }}:{{ .Values.config.http.bind_address | default 8086 }} | ||
|
||
You can connect to the remote instance with the cnos CLI. To forward the API port to localhost:8086, run the following: | ||
|
||
kubectl port-forward --namespace {{ .Release.Namespace }} $(kubectl get pods --namespace {{ .Release.Namespace }} -l app={{ include "cnosdb.fullname" . }} -o jsonpath='{ .items[0].metadata.name }') 8086:{{ .Values.config.http.bind_address | default 8086 }} | ||
|
||
You can also connect to the cnos CLI from inside the container. To open a shell session in the CnosDB pod, run the following: | ||
|
||
kubectl exec -i -t --namespace {{ .Release.Namespace }} $(kubectl get pods --namespace {{ .Release.Namespace }} -l app={{ include "cnosdb.fullname" . }} -o jsonpath='{.items[0].metadata.name}') /bin/sh | ||
|
||
To view the logs for the CnosDB pod, run the following: | ||
|
||
kubectl logs -f --namespace {{ .Release.Namespace }} $(kubectl get pods --namespace {{ .Release.Namespace }} -l app={{ include "cnosdb.fullname" . }} -o jsonpath='{ .items[0].metadata.name }') | ||
|
||
{{- if .Values.setDefaultUser.enabled }} | ||
|
||
To retrieve the default user name: | ||
|
||
{{- if .Values.setDefaultUser.user.existingSecret }} | ||
|
||
echo $(kubectl get secret {{ .Values.setDefaultUser.user.existingSecret }} -o "jsonpath={.data['cnosdb-user']}" --namespace {{ .Release.Namespace }} | base64 --decode) | ||
|
||
{{- else }} | ||
|
||
echo $(kubectl get secret {{ include "cnosdb.fullname" . }}-auth -o "jsonpath={.data['cnosdb-user']}" --namespace {{ .Release.Namespace }} | base64 --decode) | ||
|
||
{{- end }} | ||
|
||
To retrieve the default user password: | ||
|
||
{{- if .Values.setDefaultUser.user.existingSecret }} | ||
|
||
echo $(kubectl get secret {{ .Values.setDefaultUser.user.existingSecret }} -o "jsonpath={.data['cnosdb-password']}" --namespace {{ .Release.Namespace }} | base64 --decode) | ||
|
||
{{- else }} | ||
|
||
echo $(kubectl get secret {{ include "cnosdb.fullname" . }}-auth -o "jsonpath={.data['cnosdb-password']}" --namespace {{ .Release.Namespace }} | base64 --decode) | ||
|
||
{{- end }} | ||
{{- end }} | ||
todo |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.