mirror of
https://github.com/komodorio/helm-dashboard.git
synced 2026-03-26 06:18:04 +00:00
Compare commits
4 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
cb535b1308 | ||
|
|
c6b1586e88 | ||
|
|
bae6650263 | ||
|
|
d0836eee0e |
18
Dockerfile
18
Dockerfile
@@ -1,10 +1,12 @@
|
|||||||
# Stage - builder
|
# Stage - builder
|
||||||
FROM golang as builder
|
FROM golang as builder
|
||||||
|
|
||||||
|
ARG VER
|
||||||
|
|
||||||
ENV GOOS=linux
|
ENV GOOS=linux
|
||||||
ENV GOARCH=amd64
|
ENV GOARCH=amd64
|
||||||
ENV CGO_ENABLED=0
|
ENV CGO_ENABLED=0
|
||||||
|
ENV VERSION=0.0.0
|
||||||
|
|
||||||
WORKDIR /build
|
WORKDIR /build
|
||||||
|
|
||||||
@@ -13,9 +15,6 @@ COPY go.sum ./
|
|||||||
COPY main.go ./
|
COPY main.go ./
|
||||||
RUN go mod download
|
RUN go mod download
|
||||||
|
|
||||||
ARG VER=0.0.0
|
|
||||||
ENV VERSION=${VER}
|
|
||||||
|
|
||||||
ADD . src
|
ADD . src
|
||||||
|
|
||||||
WORKDIR /build/src
|
WORKDIR /build/src
|
||||||
@@ -25,18 +24,15 @@ RUN make build
|
|||||||
# Stage - runner
|
# Stage - runner
|
||||||
FROM alpine/helm
|
FROM alpine/helm
|
||||||
|
|
||||||
# Python
|
|
||||||
RUN apk add --update --no-cache python3 && python3 -m ensurepip && pip3 install --upgrade pip setuptools
|
|
||||||
|
|
||||||
# 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
|
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
|
||||||
|
|
||||||
|
# Checkov scanner
|
||||||
|
RUN apk add --update --no-cache python3
|
||||||
|
RUN python3 -m ensurepip
|
||||||
|
RUN pip3 install checkov
|
||||||
|
|
||||||
# Trivy
|
# Trivy
|
||||||
RUN curl -sfL https://raw.githubusercontent.com/aquasecurity/trivy/main/contrib/install.sh | sh -s -- -b /usr/local/bin v0.18.3
|
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
|
COPY --from=builder /build/src/bin/dashboard /bin/helm-dashboard
|
||||||
|
|
||||||
|
|||||||
@@ -3,7 +3,7 @@ type: application
|
|||||||
|
|
||||||
name: helm-dashboard
|
name: helm-dashboard
|
||||||
description: A GUI Dashboard for Helm by Komodor
|
description: A GUI Dashboard for Helm by Komodor
|
||||||
icon: "https://raw.githubusercontent.com/komodorio/helm-dashboard/main/pkg/dashboard/static/logo.svg"
|
icon: "https://github.com/komodorio/helm-dashboard/blob/main/pkg/dashboard/static/logo.png"
|
||||||
|
|
||||||
version: 0.1.1
|
version: 0.1.0
|
||||||
appVersion: "0.3.0"
|
appVersion: "0.0.0"
|
||||||
|
|||||||
@@ -49,7 +49,7 @@ The following table lists the configurable parameters of the chart and their def
|
|||||||
| `image.tag` | Image tag | |
|
| `image.tag` | Image tag | |
|
||||||
| `image.pullPolicy` | Image pull policy | `IfNotPresent` |
|
| `image.pullPolicy` | Image pull policy | `IfNotPresent` |
|
||||||
| `replicaCount` | Number of dashboard Pods to run | `1` |
|
| `replicaCount` | Number of dashboard Pods to run | `1` |
|
||||||
| `dashboard.allowWriteActions` | Enables write actions. Allow modifying, deleting and creating charts and kubernetes resources. | `true` |
|
| `dashboard.allowWriteActions` | Enables write actions. Allow modifying, deleting and creating charts and kubernetes resources. | `false` |
|
||||||
| `resources.requests.cpu` | CPU resource requests | `200m` |
|
| `resources.requests.cpu` | CPU resource requests | `200m` |
|
||||||
| `resources.limits.cpu` | CPU resource limits | `1` |
|
| `resources.limits.cpu` | CPU resource limits | `1` |
|
||||||
| `resources.requests.memory` | Memory resource requests | `256Mi` |
|
| `resources.requests.memory` | Memory resource requests | `256Mi` |
|
||||||
|
|||||||
@@ -17,11 +17,11 @@ apiVersion: rbac.authorization.k8s.io/v1
|
|||||||
metadata:
|
metadata:
|
||||||
name: {{ include "helm-dashboard.serviceAccountName" . }}
|
name: {{ include "helm-dashboard.serviceAccountName" . }}
|
||||||
rules:
|
rules:
|
||||||
- apiGroups: ["*"]
|
- apiGroups: ["", "apps", "rbac.authorization.k8s.io", "rbac", "batch", "extensions", "networking.k8s.io", "storage.k8s.io"]
|
||||||
resources: ["*"]
|
resources: ["*"]
|
||||||
verbs: ["get", "list", "watch"]
|
verbs: ["get", "list", "watch"]
|
||||||
{{- if .Values.dashboard.allowWriteActions }}
|
{{- if .Values.dashboard.allowWriteActions }}
|
||||||
- apiGroups: ["*"]
|
- apiGroups: ["", "apps", "rbac.authorization.k8s.io", "rbac", "batch", "extensions", "networking.k8s.io", "storage.k8s.io"]
|
||||||
resources: ["*"]
|
resources: ["*"]
|
||||||
verbs: ["get", "list", "watch", "create", "delete", "patch", "update"]
|
verbs: ["get", "list", "watch", "create", "delete", "patch", "update"]
|
||||||
{{- end }}
|
{{- end }}
|
||||||
|
|||||||
@@ -26,7 +26,7 @@ resources:
|
|||||||
memory: 1Gi
|
memory: 1Gi
|
||||||
|
|
||||||
dashboard:
|
dashboard:
|
||||||
allowWriteActions: true
|
allowWriteActions: false
|
||||||
persistence:
|
persistence:
|
||||||
enabled: true
|
enabled: true
|
||||||
|
|
||||||
|
|||||||
@@ -5,7 +5,7 @@ xhr.onload = function () {
|
|||||||
const version = status.CurVer
|
const version = status.CurVer
|
||||||
if (status.Analytics) {
|
if (status.Analytics) {
|
||||||
enableDD(version)
|
enableDD(version)
|
||||||
enableHeap(version, status.ClusterMode)
|
enableHeap(version)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -42,7 +42,7 @@ function enableDD(version) {
|
|||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
function enableHeap(version, inCluster) {
|
function enableHeap(version) {
|
||||||
window.heap = window.heap || [], heap.load = function (e, t) {
|
window.heap = window.heap || [], heap.load = function (e, t) {
|
||||||
window.heap.appid = e, window.heap.config = t = t || {};
|
window.heap.appid = e, window.heap.config = t = t || {};
|
||||||
let r = document.createElement("script");
|
let r = document.createElement("script");
|
||||||
@@ -56,10 +56,7 @@ function enableHeap(version, inCluster) {
|
|||||||
}, p = ["addEventProperties", "addUserProperties", "clearEventProperties", "identify", "resetIdentity", "removeEventProperty", "setEventProperties", "track", "unsetEventProperty"], o = 0; o < p.length; o++) heap[p[o]] = n(p[o])
|
}, 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");
|
heap.load("4249623943");
|
||||||
window.heap.addEventProperties({
|
window.heap.addEventProperties({'version': version});
|
||||||
'version': version,
|
|
||||||
'installationMode': inCluster?"cluster":"local"
|
|
||||||
});
|
|
||||||
}
|
}
|
||||||
|
|
||||||
function sendStats(name, prop){
|
function sendStats(name, prop){
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
name: "dashboard"
|
name: "dashboard"
|
||||||
version: "0.3.1"
|
version: "0.3.0"
|
||||||
usage: "A simplified way of working with Helm"
|
usage: "A simplified way of working with Helm"
|
||||||
description: "View HELM situation in nice web UI"
|
description: "View HELM situation in nice web UI"
|
||||||
command: "$HELM_PLUGIN_DIR/bin/helm-dashboard"
|
command: "$HELM_PLUGIN_DIR/bin/helm-dashboard"
|
||||||
|
|||||||
Reference in New Issue
Block a user