Skip to content

Commit

Permalink
docs: new documents for helm-installer plugin
Browse files Browse the repository at this point in the history
Signed-off-by: Daniel Hu <tao.hu@merico.dev>
  • Loading branch information
daniel-hutao committed Nov 1, 2022
1 parent 030bd2f commit 4b8ad85
Show file tree
Hide file tree
Showing 23 changed files with 582 additions and 693 deletions.
15 changes: 14 additions & 1 deletion docs/plugins/helm-installer/argocd.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,16 @@
# Install Argo CD with DevStream

//TODO(daniel-hutao): to be updated
## Default Configs

| key | default value | description |
| ---------------- | ------------------------------------ | ------------------------------------------------ |
| chart.chartPath | "" | local chart path |
| chart.chartName | argo/argo-cd | chart name |
| chart.version | "" | chart version |
| chart.timeout | 10m | this config will wait 10 minutes to deploy Argo CD |
| chart.upgradeCRDs | true | default update CRD config |
| chart.releaseName | argocd | helm release name |
| chart.namespace | argocd | namespace where helm to deploy |
| chart.wait | true | whether to wait until installation is complete |
| repo.url | https://argoproj.github.io/argo-helm | helm official repo address |
| repo.name | argo | helm repo name |
15 changes: 14 additions & 1 deletion docs/plugins/helm-installer/argocd.zh.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,16 @@
# 使用 DevStream 部署 Argo CD

//TODO(daniel-hutao): to be updated
## 默认配置

| 配置项 | 默认值 | 描述 |
| ---- | ---- | ---- |
| chart.chartPath | "" | 本地 chart 包路径 |
| chart.chartName | argo/argo-cd | chart 包名称 |
| chart.version | "" | chart 包版本 |
| chart.timeout | 10m | helm install 的超时时间 |
| chart.upgradeCRDs | true | 是否更新 CRDs(如果有) |
| chart.releaseName | argocd | helm 发布名称 |
| chart.namespace | argocd | 部署的命名空间 |
| chart.wait | true | 是否等待部署完成 |
| repo.url | https://argoproj.github.io/argo-helm | helm 仓库地址 |
| repo.name | argo | helm 仓库名 |
53 changes: 18 additions & 35 deletions docs/plugins/helm-installer/artifactory.md
Original file line number Diff line number Diff line change
@@ -1,12 +1,20 @@
# Install Artifactory with DevStream

//TODO(daniel-hutao): to be updated
## Default Configs

This plugin installs [artifactory](https://jfrog.com/artifactory/) in an existing Kubernetes cluster using the Helm chart.

## Usage
| key | default value | description |
| ---- | ---- | ---- |
| chart.chartPath | "" | local chart path |
| chart.chartName | jfrog/artifactory | chart name |
| chart.timeout | 10m | this config will wait 10 minutes to deploy |
| chart.releaseName | artifactory | helm release name |
| chart.upgradeCRDs | true | default update CRD config |
| chart.wait | true | whether to wait until installation is complete |
| chart.namespace | artifactory | namespace where helm to deploy |
| repo.url | https://charts.jfrog.io | offical helm repo address |
| repo.name | jfrog | helm repo name |

### Test/Local Dev Environment
## Test/Local Dev Environment

If you want to **test the plugin locally**, The following `valuesYaml` configuration can be used

Expand All @@ -26,41 +34,16 @@ In this configuration
- local disks on machines in the cluster are defaulted used for data mounting.
- Using `nodePort` to expose service, You can access `artifactory` by domain `http://{{k8s node IP}}:30002`. The default account name and password are admin/password (please replace the default account password in the production environment).

### Production Environment
## Production Environment

#### External Storage
### External Storage

- PostgreSQL: Set the `database.url` to Postgresql's address. More info can be found in [Config](https://www.jfrog.com/confluence/display/JFROG/Configuring+the+Database).

#### Disk Storage
### Disk Storage

You can set `customVolumes` and `customVolumeMounts` for this service. More info can be found in [Config](https://www.jfrog.com/confluence/display/JFROG/Configuring+the+Filestore).

#### Network Config

This plugin support`Ingress`, `ClusterIP`, `NodePort` and `LoadBalancer` , You can give choice to your needs.

### Config

The following content is an example of the "tool file".

For more information on the main config, the tool file and the var file of DevStream, see [Core Concepts Overview](../core-concepts/core-concepts.md#1-config) and [DevStream Configuration](../core-concepts/config.md).
### Network Config

```yaml
--8<-- "artifactory.yaml"
```

#### Default Configs

| key | default value | description |
| ---- | ---- | ---- |
| chart.chartPath | "" | local chart path |
| chart.chartName | jfrog/artifactory | chart name |
| chart.timeout | 10m | this config will wait 10 minutes to deploy |
| chart.releaseName | artifactory | helm release name |
| chart.upgradeCRDs | true | default update CRD config |
| chart.wait | true | whether to wait until installation is complete |
| chart.namespace | artifactory | namespace where helm to deploy |
| repo.url | https://charts.jfrog.io | offical helm repo address |
| repo.name | jfrog | helm repo name |
Currently, except for `valuesYaml` and default configs, all the parameters in the example above are mandatory.
This plugin support `Ingress`, `ClusterIP`, `NodePort` and `LoadBalancer` , You can give choice to your needs.
53 changes: 18 additions & 35 deletions docs/plugins/helm-installer/artifactory.zh.md
Original file line number Diff line number Diff line change
@@ -1,12 +1,21 @@
# 使用 DevStream 部署 Artifactory

//TODO(daniel-hutao): to be updated
## 默认配置

这个插件使用 helm 在已有的 k8s 集群上安装 [artifactory](https://jfrog.com/artifactory/)

## 使用方法
| key | default value | description |
| ---- | ---- | ---- |
| chart.chartPath | "" | 本地 chart 包路径 |
| chart.chartName | jfrog/artifactory | chart 名称 |
| chart.version | "" | chart 版本 |
| chart.timeout | 10m | 等待部署成功的时间 |
| chart.upgradeCRDs | true | 默认更新 CRD 配置(如果存在的话) |
| chart.releaseName | artifactory | helm 发布名称 |
| chart.namespace | artifactory | helm 部署的命名空间名称 |
| chart.wait | true | 是否等待部署完成 |
| repo.url | https://charts.jfrog.io | helm 官方仓库地址 |
| repo.name | jfrog | helm 仓库名 |

### 测试环境
## 测试环境

如果你想在**本地测试插件**, 可以使用如下 `valuesYaml` 配置。

Expand All @@ -26,42 +35,16 @@ valuesYaml: |
- 数据挂载的磁盘默认会使用集群上机器的本地磁盘;
- 通过 `NodePort` 对外暴露服务,可使用 `http://{{k8s 节点ip}}:30002` 域名来访问,默认账号名密码为 admin/password (生产环境请替换默认账号密码)。

### 生产环境
## 生产环境

#### 外部存储
### 外部存储

- PostgreSQL:设置 `database.url` 来设置数据库地址,具体配置可参考 [Config](https://www.jfrog.com/confluence/display/JFROG/Configuring+the+Database) 中的选项。

#### 磁盘存储
### 磁盘存储

可以设置 `customVolumes` 和 `customVolumeMounts` 来配置挂载磁盘,具体配置可参考 [Config](https://www.jfrog.com/confluence/display/JFROG/Configuring+the+Filestore)。

#### 网络层配置
### 网络层配置

该插件支持 `Ingress`, `ClusterIP`, `NodePort`, `LoadBalancer` 对外暴露的模式,可以基于需求进行选择。

### 配置

下面的配置文件展示的是"tool file"的内容。

关于更多关于DevStream的主配置、tool file、var file的信息,请阅读[核心概念概览](../core-concepts/core-concepts.zh.md)和[DevStream配置](../core-concepts/config.zh.md).

```yaml
--8<-- "artifactory.yaml"
```

#### 默认配置

| key | default value | description |
| ---- | ---- | ---- |
| chart.chartPath | "" | 本地 chart 包路径 |
| chart.chartName | jfrog/artifactory | helm 包名称 |
| chart.timeout | 10m | 等待部署成功的时间 |
| chart.upgradeCRDs | true | 默认更新 CRD 配置(如果存在的话) |
| chart.releaseName | artifactory | helm 发布名称 |
| chart.wait | true | 是否等待部署完成 |
| chart.namespace | artifactory | helm 部署的命名空间名称 |
| repo.url | https://charts.jfrog.io | helm 官方仓库地址 |
| repo.name | jfrog | helm 仓库名 |

目前除了 `valuesYaml` 字段和默认配置,其它所有示例参数均为必填项。
23 changes: 13 additions & 10 deletions docs/plugins/helm-installer/devlake.md
Original file line number Diff line number Diff line change
@@ -1,13 +1,16 @@
# Install DevLake with DevStream

//TODO(daniel-hutao): to be updated
## Default Configs

## Usage

The following content is an example of the "tool file".

For more information on the main config, the tool file and the var file of DevStream, see [Core Concepts Overview](../core-concepts/core-concepts.md#1-config) and [DevStream Configuration](../core-concepts/config.md).

``` yaml
--8<-- "devlake.yaml"
```
| key | default value | description |
| ---------------- | ------------------------------------ | ------------------------------------------------ |
| chart.chartPath | "" | local chart path |
| chart.chartName | "devlake/devlake | chart name |
| chart.version | "" | chart version |
| chart.timeout | 10m | this config will wait 10 minutes to deploy DevLake |
| chart.upgradeCRDs | true | default update CRD config |
| chart.releaseName | devlake | helm release name |
| chart.namespace | devlake | namespace where helm to deploy |
| chart.wait | true | whether to wait until installation is complete |
| repo.url | https://merico-dev.github.io/devlake-helm-chart | helm official repo address |
| repo.name | devlake | helm repo name |
23 changes: 13 additions & 10 deletions docs/plugins/helm-installer/devlake.zh.md
Original file line number Diff line number Diff line change
@@ -1,13 +1,16 @@
# 使用 DevStream 部署 DevLake

//TODO(daniel-hutao): to be updated
## 默认配置

## 用例

下面的配置文件展示的是"tool file"的内容。

关于更多关于DevStream的主配置、tool file、var file的信息,请阅读[核心概念概览](../core-concepts/core-concepts.zh.md)[DevStream配置](../core-concepts/config.zh.md).

``` yaml
--8<-- "devlake.yaml"
```
| 配置项 | 默认值 | 描述 |
| ---- | ---- | ---- |
| chart.chartPath | "" | 本地 chart 包路径 |
| chart.chartName | devlake/devlake | chart 包名称 |
| chart.version | "" | chart 包版本 |
| chart.timeout | 10m | helm install 的超时时间 |
| chart.upgradeCRDs | true | 是否更新 CRDs(如果有) |
| chart.releaseName | devlake | helm 发布名称 |
| chart.namespace | devlake | 部署的命名空间 |
| chart.wait | true | 是否等待部署完成 |
| repo.url | https://merico-dev.github.io/devlake-helm-chart | helm 仓库地址 |
| repo.name | devlake | helm 仓库名 |
53 changes: 15 additions & 38 deletions docs/plugins/helm-installer/harbor.md
Original file line number Diff line number Diff line change
@@ -1,15 +1,5 @@
# Install Harbor with DevStream

//TODO(daniel-hutao): to be updated

The `harbor` plugin is used to deploy and manage [Harbor](https://goharbor.io/).

Currently, two popular ways to deploy Harbor are using _docker compose_or _helm_.

There are also two DevStream plugins, `harbor-docker` (docker-compose deployment) and `harbor` (helm deployment.) They will be merged into one soon, but we mainly use the helm one at the moment.

In this doc, we will do a development environment deploy with minikube/kind. You can do the same in any Kubernetes cluster, but some steps need adjustment.

## 1 Prerequisites

- An existing Kubernetes cluster, version > 1.10
Expand All @@ -35,35 +25,28 @@ Examples:

### 3.1 Quickstart

The following content is an example of the "tool file".

For more information on the main config, the tool file and the var file of DevStream, see [Core Concepts Overview](../core-concepts/core-concepts.md#1-config) and [DevStream Configuration](../core-concepts/config.md).

For a local testing and developing purpose, we can deploy Harbor quickly using the minimal config as follows:

```yaml
tools:
- name: harbor
instanceID: default
- name: helm-installer
instanceID: harbor-001
dependsOn: [ ]
options:
chart:
valuesYaml: |
externalURL: http://127.0.0.1
expose:
type: nodePort
tls:
enabled: false
chartmuseum:
enabled: false
notary:
enabled: false
trivy:
valuesYaml: |
externalURL: http://127.0.0.1
expose:
type: nodePort
tls:
enabled: false
chartmuseum:
enabled: false
notary:
enabled: false
trivy:
enabled: false
```
_Note: the config above is the "tool config" of DevStream. For a full DevStream config, we need the core config. See [here](../core-concepts/config.md)._
After running `dtm apply`, we can see the following resources in the "harbor" namespace:

- **Deployment** (`kubectl get deployment -n harbor`)
Expand Down Expand Up @@ -148,7 +131,6 @@ And the default login user/pwd is: `admin/Harbor12345`. You will see the dashboa

![Harbor Dashboard](./harbor/dashboard.png)


### 3.3 Default Config

The `harbor` plugin provides default values for many options:
Expand All @@ -157,16 +139,11 @@ The `harbor` plugin provides default values for many options:
| ---- | ---- | ---- |
| chart.chartPath | "" | local chart path |
| chart.chartName | harbor/harbor | helm chart name |
| chart.version | "" | chart version |
| chart.timeout | 10m | timeout for helm install |
| chart.upgradeCRDs | true | update CRDs or not (if any) |
| chart.releaseName | harbor | helm release name |
| chart.wait | true | wait till deployment finishes |
| chart.namespace | harbor | namespace |
| chart.wait | true | wait till deployment finishes |
| repo.url | https://helm.goharbor.io | helm repo URL |
| repo.name | harbor | helm repo name |

A maximum config is as follows:

```yaml
--8<-- "harbor.yaml"
```
Loading

0 comments on commit 4b8ad85

Please sign in to comment.