8 Commits

Author SHA1 Message Date
ronahk
eef3cd94b7 release 0.3.1 2022-12-19 14:23:55 +02:00
Andrey Pohilko
e9abedbadb Merge branch 'main' of github.com:komodorio/helm-dashboard 2022-12-19 12:38:17 +02:00
Andrey Pohilko
5d0a148fea Add installMode to analytics 2022-12-19 12:38:03 +02:00
ronahk
c0cf6237e6 Helm chart updates (#141)
* update plugin version

* fix pipeline

* fix pipeline

* add needs

* update chart icon

* allow all api groups

* allow write actions by default
2022-12-19 12:29:52 +02:00
Andrey Pohilko
9876b6a12e Merge branch 'main' of github.com:komodorio/helm-dashboard 2022-12-19 12:27:20 +02:00
Andrey Pohilko
90815f2271 Pass version to container image correctly 2022-12-19 12:27:02 +02:00
Eddie Garcia
e83ddbb15d Release 0.3.0 (#140) 2022-12-19 11:35:18 +02:00
komodor-bot
78f458112b Increment chart versions [skip ci] 2022-12-18 13:07:55 +00:00
8 changed files with 28 additions and 21 deletions

View File

@@ -60,7 +60,7 @@ jobs:
image:
runs-on: ubuntu-latest
needs: release
needs: [release, pre_release]
timeout-minutes: 60
steps:
- name: Check out the repo
@@ -85,13 +85,13 @@ jobs:
with:
context: .
push: ${{ github.event_name != 'pull_request' }}
tags: ${{ needs.pre_release.outputs.release_tag }}
tags: komodorio/helm-dashboard:${{ needs.pre_release.outputs.release_tag }},komodorio/helm-dashboard:latest
labels: ${{ steps.meta.outputs.labels }}
build-args: VER=${{ needs.pre_release.outputs.release_tag }}
publish_chart:
runs-on: ubuntu-latest
need: image
needs: [image, pre_release]
if: github.event_name == 'push' || github.event_name == 'workflow_dispatch'
steps:
- name: Checkout

View File

@@ -1,12 +1,10 @@
# Stage - builder
FROM golang as builder
ARG VER
ENV GOOS=linux
ENV GOARCH=amd64
ENV CGO_ENABLED=0
ENV VERSION=0.0.0
WORKDIR /build
@@ -15,6 +13,9 @@ COPY go.sum ./
COPY main.go ./
RUN go mod download
ARG VER=0.0.0
ENV VERSION=${VER}
ADD . src
WORKDIR /build/src
@@ -24,15 +25,18 @@ RUN make build
# Stage - runner
FROM alpine/helm
RUN curl -o /bin/kubectl -vf -LO "https://dl.k8s.io/release/$(curl -L -s https://dl.k8s.io/release/stable.txt)/bin/linux/amd64/kubectl" && chmod +x /bin/kubectl && kubectl --help
# Python
RUN apk add --update --no-cache python3 && python3 -m ensurepip && pip3 install --upgrade pip setuptools
# Checkov scanner
RUN apk add --update --no-cache python3
RUN python3 -m ensurepip
RUN pip3 install checkov
# kubectl
RUN curl -o /bin/kubectl -vf -LO "https://dl.k8s.io/release/$(curl -L -s https://dl.k8s.io/release/stable.txt)/bin/linux/amd64/kubectl" && chmod +x /bin/kubectl && kubectl --help
# Trivy
RUN curl -sfL https://raw.githubusercontent.com/aquasecurity/trivy/main/contrib/install.sh | sh -s -- -b /usr/local/bin v0.18.3
RUN trivy --version
# Checkov scanner
RUN pip3 install checkov packaging==21.3 && checkov --version
COPY --from=builder /build/src/bin/dashboard /bin/helm-dashboard

View File

@@ -3,7 +3,7 @@ type: application
name: helm-dashboard
description: A GUI Dashboard for Helm by Komodor
icon: "https://github.com/komodorio/helm-dashboard/blob/main/pkg/dashboard/static/logo.png"
icon: "https://raw.githubusercontent.com/komodorio/helm-dashboard/main/pkg/dashboard/static/logo.svg"
version: 0.1.0
appVersion: "0.0.0"
version: 0.1.1
appVersion: "0.3.0"

View File

@@ -49,7 +49,7 @@ The following table lists the configurable parameters of the chart and their def
| `image.tag` | Image tag | |
| `image.pullPolicy` | Image pull policy | `IfNotPresent` |
| `replicaCount` | Number of dashboard Pods to run | `1` |
| `dashboard.allowWriteActions` | Enables write actions. Allow modifying, deleting and creating charts and kubernetes resources. | `false` |
| `dashboard.allowWriteActions` | Enables write actions. Allow modifying, deleting and creating charts and kubernetes resources. | `true` |
| `resources.requests.cpu` | CPU resource requests | `200m` |
| `resources.limits.cpu` | CPU resource limits | `1` |
| `resources.requests.memory` | Memory resource requests | `256Mi` |

View File

@@ -17,11 +17,11 @@ apiVersion: rbac.authorization.k8s.io/v1
metadata:
name: {{ include "helm-dashboard.serviceAccountName" . }}
rules:
- apiGroups: ["", "apps", "rbac.authorization.k8s.io", "rbac", "batch", "extensions", "networking.k8s.io", "storage.k8s.io"]
- apiGroups: ["*"]
resources: ["*"]
verbs: ["get", "list", "watch"]
{{- if .Values.dashboard.allowWriteActions }}
- apiGroups: ["", "apps", "rbac.authorization.k8s.io", "rbac", "batch", "extensions", "networking.k8s.io", "storage.k8s.io"]
- apiGroups: ["*"]
resources: ["*"]
verbs: ["get", "list", "watch", "create", "delete", "patch", "update"]
{{- end }}

View File

@@ -26,7 +26,7 @@ resources:
memory: 1Gi
dashboard:
allowWriteActions: false
allowWriteActions: true
persistence:
enabled: true

View File

@@ -5,7 +5,7 @@ xhr.onload = function () {
const version = status.CurVer
if (status.Analytics) {
enableDD(version)
enableHeap(version)
enableHeap(version, status.ClusterMode)
}
}
}
@@ -42,7 +42,7 @@ function enableDD(version) {
})
}
function enableHeap(version) {
function enableHeap(version, inCluster) {
window.heap = window.heap || [], heap.load = function (e, t) {
window.heap.appid = e, window.heap.config = t = t || {};
let r = document.createElement("script");
@@ -56,7 +56,10 @@ function enableHeap(version) {
}, p = ["addEventProperties", "addUserProperties", "clearEventProperties", "identify", "resetIdentity", "removeEventProperty", "setEventProperties", "track", "unsetEventProperty"], o = 0; o < p.length; o++) heap[p[o]] = n(p[o])
};
heap.load("4249623943");
window.heap.addEventProperties({'version': version});
window.heap.addEventProperties({
'version': version,
'installationMode': inCluster?"cluster":"local"
});
}
function sendStats(name, prop){

View File

@@ -1,5 +1,5 @@
name: "dashboard"
version: "0.2.8"
version: "0.3.1"
usage: "A simplified way of working with Helm"
description: "View HELM situation in nice web UI"
command: "$HELM_PLUGIN_DIR/bin/helm-dashboard"