Skip to content

Commit

Permalink
improve: source refactoring & improve web-ui
Browse files Browse the repository at this point in the history
  • Loading branch information
itnpeople committed Aug 20, 2021
2 parents 2227312 + de94538 commit 8f8a6d2
Show file tree
Hide file tree
Showing 1,662 changed files with 11,278 additions and 951,459 deletions.
9 changes: 9 additions & 0 deletions .github/workflows/publish-docker.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -69,3 +69,12 @@ jobs:
tags: |
${{steps.variables.outputs.prefix}}.metrics-scraper:${{steps.variables.outputs.version}}
${{steps.variables.outputs.prefix}}.metrics-scraper:latest
- name: Build docker image [terminal]
uses: docker/build-push-action@v2
with:
context: src/app/terminal
file: src/app/terminal/Dockerfile
push: true
tags: |
${{steps.variables.outputs.prefix}}.terminal:${{steps.variables.outputs.version}}
${{steps.variables.outputs.prefix}}.terminal:latest
2 changes: 1 addition & 1 deletion .npmrc
Original file line number Diff line number Diff line change
Expand Up @@ -4,4 +4,4 @@
# npm run <script-name> --kore-board:<variable-name>=<value>
# npm run docker:build:backend --kore-board:docker_image_tag=v0.2.0
kore-board:docker_image_tag = latest
kore-board:docker_image_registry = ghcr.io/acornsoftlab
kore-board:docker_image_registry = ghcr.io/kore3lab
12 changes: 6 additions & 6 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,8 @@

### Summary

* 개발은 원본(acornosftlab/dashboard) repository를 fork 받아 로컬 repository 에서 수행하고 "Pull Reuqest"를 통해 리뷰 프로세스 수행
* 리뷰가 완료되면 원본(acornosftlab/dashboard) repository의 branch에 merge 하여 반영
* 개발은 원본(kore3lab/dashboard) repository를 fork 받아 로컬 repository 에서 수행하고 "Pull Reuqest"를 통해 리뷰 프로세스 수행
* 리뷰가 완료되면 원본(kore3lab/dashboard) repository의 branch에 merge 하여 반영
* Feature 개발 : `develop` branch에서 로컬 branch를 생성&개발 후 원본 repository의 `develop` branch에 merge
* Hotfix 개발 : `master` branch에서 로컬 branch를 생성&개발 후 원본 repository의 `develop``master` branch에 merge
* Release 개발 : `develop` branch에서 로컬 branch를 생성&개발 후 원본 repository의 `masater``develop` branch에 merge
Expand All @@ -37,14 +37,14 @@ origin https://github.com/<github id>/dashboard.git (push)
원격 저장소(프로젝트의 원래 저장소)를 추가한다.

```
$ git remote add upstream https://github.com/acornsoftlab/dashboard.git
$ git remote add upstream https://github.com/kore3lab/dashboard.git
$ git remote -v
origin https://github.com/<github id>/dashboard.git (fetch)
origin https://github.com/<github id>/dashboard.git (push)
upstream https://github.com/acornsoftlab/dashboard.git (fetch)
upstream https://github.com/acornsoftlab/dashboard.git (push)
upstream https://github.com/kore3lab/dashboard.git (fetch)
upstream https://github.com/kore3lab/dashboard.git (push)
```

### 개발 준비
Expand Down Expand Up @@ -79,7 +79,7 @@ $ git branch
master
```

* [README.md](https://github.com/acornsoftlab/dashboard/blob/master/README.md)에서 "Getting started" 섹션의 clone 이후 내용을 참고하여 개발환경 구성
* [README.md](https://github.com/kore3lab/dashboard/blob/master/README.md)에서 "Getting started" 섹션의 clone 이후 내용을 참고하여 개발환경 구성



Expand Down
6 changes: 3 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# Kore Board :whale:
> Kubernetes multi-clusters dashboard
![Version](https://img.shields.io/github/release/acornsoftlab/dashboard) ![License](https://img.shields.io/github/license/acornsoftlab/dashboard) ![code size](https://img.shields.io/github/languages/code-size/acornsoftlab/dashboard) ![issues](https://img.shields.io/github/issues/acornsoftlab/dashboard) ![issues](https://img.shields.io/github/issues-closed/acornsoftlab/dashboard) ![pull requests](https://img.shields.io/github/issues-pr-closed/acornsoftlab/dashboard)
![Version](https://img.shields.io/github/release/kore3lab/dashboard) ![License](https://img.shields.io/github/license/kore3lab/dashboard) ![code size](https://img.shields.io/github/languages/code-size/kore3lab/dashboard) ![issues](https://img.shields.io/github/issues/kore3lab/dashboard) ![issues](https://img.shields.io/github/issues-closed/kore3lab/dashboard) ![pull requests](https://img.shields.io/github/issues-pr-closed/kore3lab/dashboard)

Kore-board is a web-based UI for Kubernetes multi-clusters management. It allows users to manage applications running in the multi-clusters as well as the cluster itself.
Kore보드는 쿠버네티스 다중 클러스터 관리를 위한 웹 기반 UI입니다. 사용자는 다중 클러스터에서 실행되고 있는 애플리케이션 뿐만 아니라 클러스터 자체를 관리할 수 있습니다.
Expand All @@ -13,15 +13,15 @@ Kore보드는 쿠버네티스 다중 클러스터 관리를 위한 웹 기반 UI
### Installation

```
$ kubectl apply -f https://raw.githubusercontent.com/acornsoftlab/dashboard/master/scripts/install/kuberntes/recommended.yaml
$ kubectl apply -f https://raw.githubusercontent.com/kore3lab/dashboard/master/scripts/install/kuberntes/recommended.yaml
```

See [Installation Guide](./docs/user/installation.md) page for more information

### Access

1. Open in your browser `http://<cluster-ip>:30080/`
2. On the sign-in page, enter "acornsoft" as a token string and sign in
2. On the sign-in page, enter "kore3lab" as a token string and sign in



Expand Down
4 changes: 2 additions & 2 deletions docs/developer/app-terminal.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@

### 전체 주요 프로세스

![termianl process](http://www.plantuml.com/plantuml/proxy?cache=no&src=https://raw.githubusercontent.com/acornsoftlab/dashboard/master/docs/developer/app-terminal.puml)
![termianl process](http://www.plantuml.com/plantuml/proxy?cache=no&src=https://raw.githubusercontent.com/kore3lab/dashboard/master/docs/developer/app-terminal.puml)

### Linux `unshare` 명령을 활용

Expand Down Expand Up @@ -79,7 +79,7 @@ $ curl http://localhost:3003/healthy
```
$ docker run --rm -d --privileged -p 3003:3003 --name terminal \
-v "${HOME}/.kube:/app/.kube"\
ghcr.io/acornsoftlab/kore-board.terminal:latest --kubeconfig=/app/.kube/config --corsonoff=off
ghcr.io/kore3lab/kore-board.terminal:latest --kubeconfig=/app/.kube/config --corsonoff=off
```

### 클라이언트 활용 (예제 코드)
Expand Down
26 changes: 1 addition & 25 deletions docs/developer/getting-started.md
Original file line number Diff line number Diff line change
Expand Up @@ -16,34 +16,10 @@
* clone

```
$ git clone https://github.com/acornsoftlab/dashboard.git
$ git clone https://github.com/kore3lab/dashboard.git
$ cd dashboard
```

* `subtree`로 구성된 소스 중 사용되지 않는 파일을 제외하도록 지정하고 소스 트리를 업데이트합니다.

```
# sparse checkout 옵션 지정
$ git config core.sparsecheckout true
# 대상 파일 지정
$ cat <<EOF> .git/info/sparse-checkout
/*
!/src/app/metrics-scraper
/src/app/metrics-scraper/hack/build.sh
/src/app/metrics-scraper/pkg
/src/app/metrics-scraper/vendor
/src/app/metrics-scraper/Dockerfile
/src/app/metrics-scraper/go.*
/src/app/metrics-scraper/*.go
!/src/app/metrics-scraper/**/*_test.go
EOF
# 트리 업데이트
$ git read-tree HEAD -m -u
```


* Installation dependencies (frontend,graph)

```
Expand Down
18 changes: 11 additions & 7 deletions docs/developer/helm-chart.md
Original file line number Diff line number Diff line change
@@ -1,9 +1,15 @@
# Packaging Helm-chart

* validation

```
$ helm lint scripts/install/kuberntes/helm-chart
```

* output to yaml

```
$ helm template --debug -n kore kore-board ./kuberntes/helm-chart/ \
$ helm template -n kore kore-board scripts/install/kuberntes/helm-chart \
--set frontend.service.type=NodePort \
--set frontend.service.nodePort=30080
```
Expand All @@ -12,7 +18,7 @@ $ helm template --debug -n kore kore-board ./kuberntes/helm-chart/ \

```
$ kubectl create ns kore
$ helm template --debug -n kore kore-board ./kuberntes/helm-chart/ \
$ helm template --debug -n kore kore-board scripts/install/kuberntes/helm-chart \
--set frontend.service.type=NodePort \
--set frontend.service.nodePort=30080 \
| kubectl apply -n kore -f -
Expand All @@ -22,16 +28,14 @@ $ helm template --debug -n kore kore-board ./kuberntes/helm-chart/ \
* dry-run

```
$ helm install --dry-run --debug -n kore kore-board ./kuberntes/helm-chart/ \
$ helm install --dry-run -n kore kore-board scripts/install/kuberntes/helm-chart \
--set frontend.service.type=NodePort \
--set frontend.service.nodePort=30080
```



* packaging helm-chart

```
$ helm package helm-chart/ # packaging (tgz file 생성)
$ helm repo index . # index.yaml 파일 생성/수정
$ helm package scripts/install/kuberntes/helm-chart -d scripts/install/kuberntes # packaging (tgz file 생성)
$ helm repo index scripts/install/kuberntes # index.yaml 파일 생성/수정
```
4 changes: 2 additions & 2 deletions docs/user/config-kubeconfigs.md
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ kubeconfig=strategy=configmap,configmap=kore-board-kubeconfig,namespace=kore,fil
spec:
containers:
- name: backend
image: ghcr.io/acornsoftlab/kore-board.backend:latest
image: ghcr.io/kore3lab/kore-board.backend:latest
args:
- --kubeconfig=/app/.kube/config
volumeMounts:
Expand All @@ -49,7 +49,7 @@ $ kubectl create configmap kore-board-kubeconfig -n kore --from-file=config=${H
spec:
containers:
- name: backend
image: ghcr.io/acornsoftlab/kore-board.backend:latest
image: ghcr.io/kore3lab/kore-board.backend:latest
args:
- --kubeconfig=strategy=configmap,configmap=kore-board-kubeconfig,namespace=kore,filename=config
```
Expand Down
12 changes: 6 additions & 6 deletions docs/user/config-sign-in.md
Original file line number Diff line number Diff line change
Expand Up @@ -40,11 +40,11 @@ spec:
spec:
containers:
- name: backend
image: ghcr.io/acornsoftlab/kore-board.backend:latest
image: ghcr.io/kore3lab/kore-board.backend:latest
args:
- --metrics-scraper-url=http://metrics-scraper:8000
- --log-level=info
- --auth=strategy=cookie,secret=static-token,token=acornsoft
- --auth=strategy=cookie,secret=static-token,token=kore3lab
```

### static-token
Expand All @@ -55,7 +55,7 @@ spec:
spec:
containers:
- name: backend
image: ghcr.io/acornsoftlab/kore-board.backend:latest
image: ghcr.io/kore3lab/kore-board.backend:latest
args:
- --auth=strategy=<cookie/local>,secret=static-token,token=<token-string>
```
Expand All @@ -69,7 +69,7 @@ spec:
spec:
containers:
- name: backend
image: ghcr.io/acornsoftlab/kore-board.backend:latest
image: ghcr.io/kore3lab/kore-board.backend:latest
args:
- --auth=strategy=<cookie/local>,secret=static-user,username=<username>,password=<password>
```
Expand All @@ -96,7 +96,7 @@ EOF
spec:
containers:
- name: backend
image: ghcr.io/acornsoftlab/kore-board.backend:latest
image: ghcr.io/kore3lab/kore-board.backend:latest
args:
- --auth=strategy=<cookie/local>,secret=basic-auth,dir=/var/user
...
Expand All @@ -115,7 +115,7 @@ spec:
spec:
containers:
- name: backend
image: ghcr.io/acornsoftlab/kore-board.backend:latest
image: ghcr.io/kore3lab/kore-board.backend:latest
args:
- --auth=strategy=<cookie/local>,access-key=<access-token-secret>,refresh=<refresh-token-secret>,secret=service-account-token
```
Expand Down
4 changes: 2 additions & 2 deletions docs/user/config-startup-parameters.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
|--kubeconfig | |kubeconfig 파일 위치 |
|--metrics-scraper-url |http://localhost:8000 |metrics-scraper api url |
|--terminal-url |http://localhost:3003 |terminal api url |
|--auth |strategy=cookie,secret=static-token,token=acornsoft |인증처리방식 설정 |
|--auth |strategy=cookie,secret=static-token,token=kore3lab |인증처리방식 설정 |


* 환경변수 (env)
Expand All @@ -21,7 +21,7 @@
|KUBECONFIG | |"--kubeconfig" |
|METRICS_SCRAPER_URL |http://localhost:8000 |"--metrics-scraper-url" |
|TERMINAL_URL |http://localhost:3003 |"--terminal-url " |
|AUTH |strategy=cookie,secret=static-token,token=acornsoft |"--auth" |
|AUTH |strategy=cookie,secret=static-token,token=kore3lab |"--auth" |


* Configuration of authentication
Expand Down
8 changes: 4 additions & 4 deletions docs/user/installation.md
Original file line number Diff line number Diff line change
Expand Up @@ -81,21 +81,21 @@ $ docker volume create kubeconfig
$ docker run --rm -d --privileged --name terminal \
-v "kubeconfig:/app/.kube"\
ghcr.io/acornsoftlab/kore-board.terminal:latest --kubeconfig=/app/.kube/config --corsonoff=off
ghcr.io/kore3lab/kore-board.terminal:latest --kubeconfig=/app/.kube/config --corsonoff=off
$ docker run --rm -d --name metrics-scraper \
-v "kubeconfig:/app/.kube"\
-v "data:/app/data"\
ghcr.io/acornsoftlab/kore-board.metrics-scraper:latest --kubeconfig=/app/.kube/config --db-file=/app/data/metrics.db
ghcr.io/kore3lab/kore-board.metrics-scraper:latest --kubeconfig=/app/.kube/config --db-file=/app/data/metrics.db
$ docker run --rm -d --name backend \
-v "kubeconfig:/app/.kube" \
--link metrics-scraper:metrics-scraper \
ghcr.io/acornsoftlab/kore-board.backend:latest --kubeconfig=/app/.kube/config --metrics-scraper-url=http://metrics-scraper:8000 --terminal-url=http://terminal:3003
ghcr.io/kore3lab/kore-board.backend:latest --kubeconfig=/app/.kube/config --metrics-scraper-url=http://metrics-scraper:8000 --terminal-url=http://terminal:3003
$ docker run --rm -d -p 3000:80 --name frontend\
--link backend:backend --link terminal:terminal\
ghcr.io/acornsoftlab/kore-board.frontend:latest
ghcr.io/kore3lab/kore-board.frontend:latest
```

* clean-up
Expand Down
38 changes: 38 additions & 0 deletions package-lock.json

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

6 changes: 3 additions & 3 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
{
"name": "kore-board",
"version": "0.3.3",
"version": "0.4.0",
"description": "Kubernetes multi-clusters dashboard",
"repository": {
"type": "git",
"url": "https://github.com/acornsoftlab/dashboard.git"
"url": "https://github.com/kore3lab/dashboard.git"
},
"license": " Apache-2.0 License",
"scripts": {
Expand All @@ -15,7 +15,7 @@
"start:metrics-scraper": "cd src/app/metrics-scraper; go run server.go",
"start:graph:backend": "concurrently \"npm run start:backend\" \"npm run start:graph\"",
"build:frontend": "nuxt generate",
"build:graph": "cd src/app/graph; npm run build; cd ..;cd ..;cd ..;cp src/app/graph/dist/*.js src/app/frontend/static/acorn-graph/",
"build:graph": "cd src/app/graph; npm run build; cd ..;cd ..;cd ..;cp src/app/graph/dist/*.js src/app/frontend/static/kore3lab.graph/",
"docker:build:frontend": "./scripts/docker/docker-build.sh frontend build $npm_package_config_docker_image_tag $npm_package_config_docker_image_registry",
"docker:build:backend": "./scripts/docker/docker-build.sh backend build $npm_package_config_docker_image_tag $npm_package_config_docker_image_registry",
"docker:build:metrics-scraper": "./scripts/docker/docker-build.sh metrics-scraper build $npm_package_config_docker_image_tag $npm_package_config_docker_image_registry",
Expand Down
Loading

0 comments on commit 8f8a6d2

Please sign in to comment.