mirror of
https://github.com/komodorio/helm-dashboard.git
synced 2026-03-26 14:28:04 +00:00
Compare commits
3 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
7de7c85426 | ||
|
|
8e65c555e0 | ||
|
|
2557e6b73d |
12
.github/workflows/release.yaml
vendored
12
.github/workflows/release.yaml
vendored
@@ -27,12 +27,12 @@ jobs:
|
|||||||
needs: pre_release
|
needs: pre_release
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
steps:
|
steps:
|
||||||
- name: Plugin version/Tag name Check
|
#- name: Plugin version/Tag name Check
|
||||||
if: needs.pre_release.outputs.release_tag != needs.pre_release.outputs.plugin_version
|
# if: needs.pre_release.outputs.release_tag != needs.pre_release.outputs.plugin_version
|
||||||
uses: actions/github-script@v3
|
# uses: actions/github-script@v3
|
||||||
with:
|
# with:
|
||||||
script: |
|
# script: |
|
||||||
core.setFailed('Plugin version and tag name are not equivalent!')
|
# core.setFailed('Plugin version and tag name are not equivalent!')
|
||||||
- name: Checkout
|
- name: Checkout
|
||||||
uses: actions/checkout@v3
|
uses: actions/checkout@v3
|
||||||
with:
|
with:
|
||||||
|
|||||||
@@ -36,7 +36,7 @@ func (s Server) StartServer() (string, utils.ControlChan) {
|
|||||||
os.Exit(1) // TODO: propagate error instead?
|
os.Exit(1) // TODO: propagate error instead?
|
||||||
}
|
}
|
||||||
isDevModeWithAnalytics := os.Getenv("HD_DEV_ANALYTICS") == "true"
|
isDevModeWithAnalytics := os.Getenv("HD_DEV_ANALYTICS") == "true"
|
||||||
enableAnalytics := !s.NoTracking || isDevModeWithAnalytics
|
enableAnalytics := (!s.NoTracking && s.Version != "0.0.0") || isDevModeWithAnalytics
|
||||||
data.StatusInfo = &subproc.StatusInfo{
|
data.StatusInfo = &subproc.StatusInfo{
|
||||||
CurVer: s.Version,
|
CurVer: s.Version,
|
||||||
Analytics: enableAnalytics,
|
Analytics: enableAnalytics,
|
||||||
|
|||||||
@@ -48,11 +48,12 @@ function buildChartCard(elm) {
|
|||||||
const chartNameRegex = 'v?(0|[1-9]\\d*)\\.(0|[1-9]\\d*)\\.(0|[1-9]\\d*)(?:-((?:0|[1-9]\\d*|\\d*[a-zA-Z-][0-9a-zA-Z-]*)(?:\\.(?:0|[1-9]\\d*|\\d*[a-zA-Z-][0-9a-zA-Z-]*))*))?(?:\\+([0-9a-zA-Z-]+(?:\\.[0-9a-zA-Z-]+)*))?'
|
const chartNameRegex = 'v?(0|[1-9]\\d*)\\.(0|[1-9]\\d*)\\.(0|[1-9]\\d*)(?:-((?:0|[1-9]\\d*|\\d*[a-zA-Z-][0-9a-zA-Z-]*)(?:\\.(?:0|[1-9]\\d*|\\d*[a-zA-Z-][0-9a-zA-Z-]*))*))?(?:\\+([0-9a-zA-Z-]+(?:\\.[0-9a-zA-Z-]+)*))?'
|
||||||
const chartName = elm.chart.substring(0, elm.chart.match(chartNameRegex).index - 1)
|
const chartName = elm.chart.substring(0, elm.chart.match(chartNameRegex).index - 1)
|
||||||
$.getJSON("/api/helm/repo/search?name=" + chartName).fail(function (xhr) {
|
$.getJSON("/api/helm/repo/search?name=" + chartName).fail(function (xhr) {
|
||||||
reportError("Failed to get repo name for charts", xhr)
|
// we're ok if we can't show icon and description
|
||||||
|
console.log("Failed to get repo name for charts", xhr)
|
||||||
}).done(function (data) {
|
}).done(function (data) {
|
||||||
if (data.length > 0) {
|
if (data.length > 0) {
|
||||||
$.getJSON("/api/helm/charts/show?name=" + data[0].name).fail(function (xhr) {
|
$.getJSON("/api/helm/charts/show?name=" + data[0].name).fail(function (xhr) {
|
||||||
reportError("Failed to get list of charts", xhr)
|
console.log("Failed to get chart", xhr)
|
||||||
}).done(function (data) {
|
}).done(function (data) {
|
||||||
if (data) {
|
if (data) {
|
||||||
const res = data[0];
|
const res = data[0];
|
||||||
|
|||||||
@@ -28,7 +28,7 @@ type Cache struct {
|
|||||||
}
|
}
|
||||||
|
|
||||||
func NewCache() *Cache {
|
func NewCache() *Cache {
|
||||||
gocacheClient := gocache.New(5*time.Minute, 10*time.Minute)
|
gocacheClient := gocache.New(60*time.Minute, 10*time.Minute)
|
||||||
gocacheStore := store.NewGoCache(gocacheClient)
|
gocacheStore := store.NewGoCache(gocacheClient)
|
||||||
|
|
||||||
// TODO: use tiered cache with some disk backend, allow configuring that static cache folder
|
// TODO: use tiered cache with some disk backend, allow configuring that static cache folder
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
name: "dashboard"
|
name: "dashboard"
|
||||||
version: "0.2.7"
|
version: "0.2.8"
|
||||||
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