Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Split out Kube code (with Helm & Workloads) into it's own package #475

Merged
merged 104 commits into from
Oct 2, 2020
Merged
Show file tree
Hide file tree
Changes from 2 commits
Commits
Show all changes
104 commits
Select commit Hold shift + click to select a range
cd44987
Ensure filename/no filename text in connect by file dialog is aligned…
richard-cox Jul 28, 2020
f627688
Add typed entity access and `custom-src` removal to change log (#4496)
richard-cox Aug 7, 2020
d7102e7
Fixes #4335: Create Stratos static web site with better documentation…
Aug 7, 2020
50617f7
Fix and update customization docs (#4478)
richard-cox Aug 7, 2020
b713c78
Update base README, point to website (#4488)
richard-cox Aug 7, 2020
e12f60f
Update developer docs (#4489)
richard-cox Aug 7, 2020
4209358
Fix docs (#4497)
richard-cox Aug 7, 2020
dc2d6d6
Ensure images dependent on techPreview flag are included in imagelist…
richard-cox Aug 18, 2020
4df1516
Improve clean-symlinks script (#4509)
nwmac Aug 18, 2020
3a8cd74
Change nginx ciphers and make configurable via helm chart values (#4507)
nwmac Aug 18, 2020
200726c
Update version to 4.0.1, add change log (#4514)
richard-cox Aug 18, 2020
0285873
Fix deploy from gitlab using a group's repo (#4479)
richard-cox Aug 20, 2020
ad64761
Add additional time ranges to base metrics range selector (#4480)
richard-cox Aug 20, 2020
d27a12d
Add some time saving comments to cf permissions checker (#4508)
richard-cox Aug 20, 2020
8da357a
Move tab-nav and xsrf module source files to the src folder (#4518)
nwmac Aug 21, 2020
286d508
Fix GitHub branch limit (#4510)
richard-cox Aug 21, 2020
9a70ea6
Remove use of nodejs util module (#4521)
nwmac Aug 21, 2020
77d5a20
Remove dependencies between store and core that have crept in (#4517)
nwmac Aug 21, 2020
027f9c3
Fix store testing package (#4520)
nwmac Aug 21, 2020
5214f9f
Fix the position of the header guide array (#4524)
richard-cox Aug 24, 2020
009c203
Metrics: Ensure trailing slashes are ignored when comparing URLs (#4527)
nwmac Aug 24, 2020
da6285c
Remove imports of the form 'frontend/....' (#4519)
nwmac Aug 24, 2020
307fc20
Move endpopints-health-check.ts (#4530)
nwmac Aug 24, 2020
0aefbb1
Add UMD Ids to external modules in store package (#4522)
nwmac Aug 24, 2020
55f2244
Improvements & more checks to autoscaler scheduled date tests (#4535)
richard-cox Aug 25, 2020
a0b338a
Remove api driven views (#4537)
nwmac Aug 25, 2020
0ea6632
Remove logger service and action history (#4538)
nwmac Aug 25, 2020
5eb7f0e
Add support for API keys (#4515)
ikapelyukhin Aug 25, 2020
68d5df7
Update moment imports to remove warning when building library (#4534)
nwmac Aug 25, 2020
3c157d1
Improve presentation and fix issue with development versions
nwmac Aug 25, 2020
46732d8
Merge remote-tracking branch 'origin/improve-monocular-ui' into helm-…
nwmac Aug 25, 2020
641ccf8
WIP
richard-cox Aug 26, 2020
d845669
Fix Helm upgrade bug (#4544)
nwmac Aug 26, 2020
303bbb7
Add support for Helm Upgrade and Helm history
nwmac Aug 27, 2020
62d1a77
Remove console logging
nwmac Aug 27, 2020
d2dbafd
Add comment
nwmac Aug 27, 2020
cc8e2ac
Minor tweaks following self-review
nwmac Aug 27, 2020
dc24e61
Merge remote-tracking branch 'origin/master' into helm-hub
richard-cox Aug 27, 2020
ac18f0b
WIP
richard-cox Aug 27, 2020
d665348
Merge remote-tracking branch 'origin/master' into helm-hub
richard-cox Aug 28, 2020
adcd11a
fix install button
richard-cox Aug 28, 2020
43b2c33
Fix actual helm install
richard-cox Aug 28, 2020
a0ab8b6
Remove helm repos view
richard-cox Aug 28, 2020
f6f2d9f
Store api_keys.last_used in UTC (#4541)
ikapelyukhin Sep 1, 2020
fd2ee0f
Show per endpoint type actions in endpoints table
richard-cox Aug 28, 2020
ffd0de0
Tidy up registration step
richard-cox Sep 1, 2020
8042df9
Tidy up provider interceptor pattern
richard-cox Sep 1, 2020
7916f8a
Tidy up services, fix charts list filter by repo/helm hub
richard-cox Sep 1, 2020
7247090
Add endpoint unRegisterable, make helm types sub types, tidy up
richard-cox Sep 1, 2020
412fbf2
Remove debug logging
nwmac Sep 2, 2020
c8250ee
Merge remote-tracking branch 'origin/master' into helm-features
nwmac Sep 2, 2020
cffb053
Fix whitespace
nwmac Sep 2, 2020
b560761
Add UI for Stratos API Keys (#4523)
richard-cox Sep 2, 2020
20d79e0
Minor tidy ups
nwmac Sep 2, 2020
d1915b8
Merge remote-tracking branch 'origin/master' into helm-features
nwmac Sep 2, 2020
545669a
Add basic e2e tests for API Keys (#4536)
richard-cox Sep 2, 2020
4c09409
Fix compile issue
nwmac Sep 2, 2020
9dcdcce
Fixed versions again, and bugs following subtype split
richard-cox Sep 2, 2020
043c5fd
Merge remote-tracking branch 'origin/master' into helm-hub
richard-cox Sep 2, 2020
509e018
Fix unit tests
richard-cox Sep 2, 2020
e815dc4
Add db migration script to update existing helm endpoints with repo s…
richard-cox Sep 2, 2020
3726821
Bump docusaurus version and add support for versioning (#4506)
richard-cox Sep 3, 2020
9e7e679
Fix front-end unit tests
nwmac Sep 3, 2020
b63e39a
API Keys: Make feature configurable for different user types (#4540)
ikapelyukhin Sep 4, 2020
c767913
Add docs for UAA SSO user permissions management (#4554)
richard-cox Sep 4, 2020
cfbfab8
Add basic developers guide for working with helm (#4511)
richard-cox Sep 4, 2020
0f2e499
Always show upgrade button
nwmac Sep 7, 2020
bb89eb5
Minor entity store type updates
richard-cox Sep 7, 2020
6af9d88
Enable/disable API keys UI given API keys config setting (#4559)
richard-cox Sep 7, 2020
6409469
Convert unRegisterable to registeredLimit
richard-cox Sep 7, 2020
559ecc4
Changes following review
richard-cox Sep 8, 2020
1744b9a
Merge remote-tracking branch 'origin/master' into helm-hub
richard-cox Sep 8, 2020
150da8a
Fix display of helm type in favourite cards
richard-cox Sep 8, 2020
857c54c
Multiple Fixes
richard-cox Sep 8, 2020
b844e8c
Align icons in workload summary page
richard-cox Sep 8, 2020
a987ee7
Enable linting for all packages (#4561)
richard-cox Sep 8, 2020
14125c2
Fix lint failures
richard-cox Sep 8, 2020
f5eb911
Merge remote-tracking branch 'origin/master' into helm-features
nwmac Sep 9, 2020
ed15df6
Address PR feedback
nwmac Sep 9, 2020
ac5625a
Revert
nwmac Sep 9, 2020
7114563
Remove description when checking for similar charts
nwmac Sep 10, 2020
e85f7c2
Only show button when the helm chart is available
nwmac Sep 10, 2020
051338a
Bump angular json schema form (#4564)
nwmac Sep 10, 2020
ef00d18
Docs: Update internal versions & Automate future updates (#4558)
richard-cox Sep 10, 2020
a357a83
Merge remote-tracking branch 'origin/helm-features' into helm-hub
richard-cox Sep 10, 2020
77869e1
Improve types, start work on helm hub upgrade
richard-cox Sep 10, 2020
19c6363
Fixes following merge
richard-cox Sep 10, 2020
d97a270
Merge remote-tracking branch 'origin/master' into helm-hub
richard-cox Sep 10, 2020
520aae9
Remove TODOs
richard-cox Sep 10, 2020
ab83546
Merge remote-tracking branch 'upstream/master' into merge-upstream
richard-cox Sep 10, 2020
b8b019a
Merge fixes, remove fdescribe already in master
richard-cox Sep 10, 2020
058fb38
Fix linting
richard-cox Sep 10, 2020
557778d
Merge remote-tracking branch 'origin/helm-hub' into create-kube-package
richard-cox Sep 10, 2020
2b0772a
Merge remote-tracking branch 'origin/merge-upstream' into create-kube…
richard-cox Sep 10, 2020
853b1be
Create kubernetes package
richard-cox Sep 10, 2020
6ef4327
Fix imports
richard-cox Sep 11, 2020
f9f78cf
Fix unit tests
richard-cox Sep 11, 2020
fdf6538
Merge remote-tracking branch 'origin/master' into create-kube-package
richard-cox Sep 17, 2020
bfccf06
Fixes following review
richard-cox Sep 17, 2020
6ef9d74
Merge remote-tracking branch 'origin/master' into create-kube-package
richard-cox Sep 21, 2020
8b0bf54
Fix unit tests
richard-cox Sep 21, 2020
3540db9
Merge remote-tracking branch 'origin/master' into create-kube-package
richard-cox Sep 25, 2020
2228579
Merge remote-tracking branch 'origin/master' into create-kube-package
nwmac Oct 2, 2020
d68fc84
Fix theming for suse login
nwmac Oct 2, 2020
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ <h1>Home</h1>
<a href="{{ chart.attributes.home }}" target="_blank">{{chart.attributes.home}}</a>
</div>
</div>
<div class="chartInfo__maintainers">
<div class="chartInfo__maintainers" *ngIf="maintainers.length">
<h1>Maintainers</h1>
<div *ngFor="let maintainer of maintainers">
<a href="{{ maintainerUrl(maintainer) }}" target="_blank">{{ maintainer.name }}</a>
Expand All @@ -22,7 +22,7 @@ <h1>Maintainers</h1>
<div class="chartInfo__related" *ngIf="sources.length">
<h1>Related</h1>
<div *ngFor="let source of sources">
<a href="{{ source }}" target="_blank">{{ source }}</a>
<a href="{{ source }}" class="chartInfo__related-link" target="_blank">{{ source }}</a>
</div>
</div>
</mat-card>
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,9 @@
.chartInfo {

h1 {
font-size: 18px;
}

app-panel {
box-shadow: 1px 1px 10px rgba(black, 0.07);
border: 0 !important;
Expand All @@ -11,6 +15,14 @@
}
}

&__related {
max-width: 280px;
}

&__related-link {
font-size: 14px;
}

&__properties {
overflow: auto;
display: block;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,35 +1,4 @@
<mat-card class="chart-details-usage">
<h1>Install</h1>
<mat-tab-group>
<mat-tab label="UI" *ngIf="endpointsService.hasConnectedEndpointType('k8s') | async">
<p>You can install this Helm Chart from here.</p>
<button class="chart-details-usage__install" color="primary" mat-button mat-raised-button
routerLink="/monocular/install/{{chart.id}}/{{currentVersion}}">Install</button>
</mat-tab>

<mat-tab label="Helm CLI">
<div *ngIf="showRepoInstructions" class="chart-details-usage__repository chart-details-usage__section">
<h2 class="chart-details-usage__label">Add {{ chart.attributes.repo.name }} repository</h2>
<mat-form-field>
<input matInput floatingPlaceholder=false [value]=repoAddInstructions>
</mat-form-field>
<button mat-button angulartics2On="click" angularticsEvent="RepositoryCopy">
<mat-icon svgIcon="content-copy"></mat-icon>
</button>
</div>
<div class="chart-details-usage__section">
<h2 class="chart-details-usage__label">Install chart</h2>
<mat-form-field>
<input matInput readonly floatingPlaceholder=false [value]=installInstructions>
</mat-form-field>
<button mat-button ngxClipboard angulartics2On="click">
<mat-icon svgIcon="content-copy"></mat-icon>
</button>
</div>
<p class="help-link">
<a href="https://github.com/kubernetes/helm/blob/master/docs/quickstart.md" target="_blank"
title="How to install Helm">Need Helm?</a>
</p>
</mat-tab>
</mat-tab-group>
</mat-card>
<div class="chart-details-usage__install">
<button class="chart-details-usage__install-btn" color="primary" mat-button mat-raised-button
routerLink="/monocular/install/{{chart.id}}/{{currentVersion}}">Install Chart</button>
</div>
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ mat-tab-body {
margin: 2em 0;
box-shadow: 1px 1px 10px rgba(black, 0.07);
h1 {
font-size: 18px;
margin: 0;
}

Expand All @@ -26,6 +27,12 @@ mat-tab-body {
flex-direction: column;
}

&__install {
display: flex;
justify-content: flex-end;
margin: 35px 0;
}

.mat-input-element {
.mat-input-wrapper {
margin: 1em 0 .5em;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,11 +1,15 @@
<div class="versions">
<h1>Chart Versions</h1>
<div class="version" *ngFor="let version of shownVersions()">
<span class='number' [class.selected]="isSelected(version)">
<a [href]="goToVersionUrl(version)" [routerLink]="goToVersionUrl(version)">
{{ version.attributes.version }}</a>
</span> -
<span class='creation-date'>{{ version.attributes.created | date: 'MMM d, y' }}</span>
<div class="version__table">
<div class="version__row" *ngFor="let version of shownVersions()">
<div class='version__cell number' [class.selected]="isSelected(version)">
<a [href]="goToVersionUrl(version)" [routerLink]="goToVersionUrl(version)">
<span *ngIf="version.attributes.version.length>15">{{ version.attributes.version | slice:0:16 }}...</span>
<span *ngIf="version.attributes.version.length<16">{{ version.attributes.version }}</span>
</a>
</div>
<div class='version__cell creation-date'>{{ version.attributes.created | date: 'MMM d, y' }}</div>
</div>
</div>
<div class="more-link" *ngIf="showMoreLink()">
<a (click)="setShowAllVersions()">show all...</a>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,21 +3,40 @@
.versions {

h1 {
font-size: 18px;
margin-top: 0;
}
.more-link {
margin-top: .5em;
}
}

.version {
display: block;
.version__cell {

.creation-date {
&.creation-date {
color: lighten($layout-base, 20%);
}

.number.selected {
&.number.selected {
font-weight: bold;
}
}

.version {
&__table {
display: table;
width: 100%;
}
&__row {
display: table-row;
}
&__cell {
display: table-cell;
}
}

.app-version {
h1 {
font-size: 18px;
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -32,8 +32,18 @@ export class ChartDetailsVersionsComponent {

shownVersions(): ChartVersion[] {
if (this.versions) {
return this.showAllVersions ? this.versions : this.versions.slice(0, 5);
return this.showAllVersions ? this.versions : this.getNonDevelopmentVersion().slice(0, 5);
}
return [];
}

getNonDevelopmentVersion(): ChartVersion[] {
const nonDevel: ChartVersion[] = [];
for (const version of this.versions) {
if (version.attributes.version.indexOf('-') === -1) {
nonDevel.push(version);
}
}
return nonDevel;
}
}
Original file line number Diff line number Diff line change
@@ -1,18 +1,13 @@
<app-list-item class="chart-item" [detailUrl]="goToDetailUrl()">
<app-list-item class="chart-item" [detailUrl]="goToDetailUrl()" height="auto">
<img class="list-item-logo chart-item-logo" alt="{{ chart.attributes.name }}'s logo" src="{{ iconUrl }}" />
<div class="list-item-info chart-item-info">
<h2 class="chart-item-info__title">
<a [href]="goToDetailUrl()" [routerLink]="goToDetailUrl()">
{{ chart.attributes.name }}</a>
<a [href]="goToDetailUrl()" [routerLink]="goToDetailUrl()">{{ chart.attributes.repo.name }}/{{ chart.attributes.name }}</a>
</h2>
<p>
<span class="chart-item-info__version"
*ngIf="showVersion && chart.relationships.latestChartVersion.data.app_version">
{{ chart.relationships.latestChartVersion.data.app_version }}</span>
<span class="chart-item-info__repo repo-{{chart.attributes.repo.name}}">
<a [href]="goToRepoUrl()" [routerLink]="goToRepoUrl()">
{{ chart.attributes.repo.name }}</a>
</span>
</p>
<div class="chart-item-info__description" *ngIf="showDescription">
{{ chart.attributes.description }}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@ $chart-item-logo-width: 80px;
&__title {
margin: 0;
font-weight: 500;
font-size: 16px;
cursor: pointer;
margin-bottom: 4px;

Expand All @@ -28,6 +29,10 @@ $chart-item-logo-width: 80px;
margin: 0;
}

&__version {
font-size: 14px;
}

// Remove this when chips are ready:
// https://github.com/angular/material2/issues/120
&__repo {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<div class="list-item">
<a [href]="detailUrl" [routerLink]="detailUrl">
<div class="list-item-content">
<div class="list-item-content" [ngClass]="{'list-item__auto-height': height === 'auto'}">
<div class="list-item-logo">
<ng-content select=".list-item-logo"></ng-content>
</div>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@

// Vars
$list-item-content-height: 200px;
$list-item-content-min-height: 140px;

.list-item {
border-radius: $border-radius;
Expand Down Expand Up @@ -47,4 +48,12 @@ $list-item-content-height: 200px;
word-wrap: break-word;
text-align: center;
}

&__auto-height {
height: auto;

.list-item-info {
padding: 10px 0;
}
}
}
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import { Component } from '@angular/core';
import { Component, Input } from '@angular/core';

@Component({
selector: 'app-list-item',
Expand All @@ -8,5 +8,8 @@ import { Component } from '@angular/core';
inputs: ['detailUrl']
})
export class ListItemComponent {

@Input() height = 'default';

public detailUrl: string;
}
16 changes: 15 additions & 1 deletion src/jetstream/plugins/monocular/chartsvc/foundationdb/handler.go
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,7 @@ import (
"net/http"
"sort"
"strconv"
"strings"

"github.com/helm/monocular/chartsvc/foundationdb/datastore"
"github.com/helm/monocular/chartsvc/models"
Expand Down Expand Up @@ -461,7 +462,11 @@ func SearchCharts(w http.ResponseWriter, req *http.Request, params Params) {
}

func newChartResponse(c *models.Chart) *utils.ApiResponse {
latestCV := c.ChartVersions[0]

// NWM: This was: latestCV := c.ChartVersions[0] - but this includes development charts
// FIX: This ignores development versions
latestCV := findFirstNonDevelopmentVersion(c)

return &utils.ApiResponse{
Type: "chart",
ID: c.ID,
Expand All @@ -476,6 +481,15 @@ func newChartResponse(c *models.Chart) *utils.ApiResponse {
}
}

func findFirstNonDevelopmentVersion(c *models.Chart) models.ChartVersion {
for _, chartVersion := range c.ChartVersions {
if strings.Index(chartVersion.Version, "-") == -1 {
return chartVersion
}
}
return c.ChartVersions[0]
}

func newChartListResponse(charts []*models.Chart) utils.ApiListResponse {
cl := utils.ApiListResponse{}
for _, c := range charts {
Expand Down