Skip to content
This repository has been archived by the owner on Jan 24, 2023. It is now read-only.

Commit

Permalink
Merge branch 'v3-master' into fix-metrics
Browse files Browse the repository at this point in the history
* v3-master:
  Fix quotas
  Fix post merge
  Temp fix for linting
  Remove some duped reducers - all other cf specific reducers/functions should move out following #3789
  Fix linting
  Fix three quota issues (#3782)
  Bump version and add changelog for 2.5 (#3765)
  Fix SSO tests
  Don't load demo plugin
  Remove demo plugin
  Don't send registration info in query string
  Added fav reducers back
  Don't send username/password in the URL
  Fix bug where setup is not saved and fix /uaa after setup
  Add apache2 utils to nginx package
  • Loading branch information
KlapTrap committed Aug 21, 2019
2 parents 80bf4b5 + 2509f18 commit a278bdc
Show file tree
Hide file tree
Showing 40 changed files with 401 additions and 579 deletions.
40 changes: 40 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,45 @@
# Change Log

## 2.5.0

[Full Changelog](https://github.com/cloudfoundry-incubator/stratos/compare/2.4.0...2.5.0)

This release contains a number of fixes and improvements:

**Fixes:**

- Fix connect to IBM Cloud [\#3715](https://github.com/cloudfoundry-incubator/stratos/pull/3715)
- Create route - owned domains not proposed [\#3685](https://github.com/cloudfoundry-incubator/stratos/issues/3685)
- Fixed connect endpoint issues in Firefox [\#3679](https://github.com/cloudfoundry-incubator/stratos/pull/3679)
- Fixed connect endpoint rendering issue in Firefox [\#3678](https://github.com/cloudfoundry-incubator/stratos/pull/3678)
- Fix ExpressionChangedAfterItHasBeenCheckedError exception on home page [\#3667](https://github.com/cloudfoundry-incubator/stratos/pull/3667)
- Fix bosh prometheus metrics [\#3602](https://github.com/cloudfoundry-incubator/stratos/pull/3602)
- Fix stepper height on Chrome pre v72 & Bleeding of error style in stateful-icon [\#3599](https://github.com/cloudfoundry-incubator/stratos/pull/3599)
- Remove sidenav header underline [\#3556](https://github.com/cloudfoundry-incubator/stratos/issues/3556)
- cf/spaces routes: fixed breadcrumbs path for apps [\#3572](https://github.com/cloudfoundry-incubator/stratos/pull/3572)
- No space/org shown in cell app instances page [\#3536](https://github.com/cloudfoundry-incubator/stratos/issues/3536)
- Services Marketplace: cf endpoint on card when multiple cf connected [\#3560](https://github.com/cloudfoundry-incubator/stratos/pull/3560)
- Setup screens are missing header [\#3557](https://github.com/cloudfoundry-incubator/stratos/issues/3557)
- /uaa page is still available in a configured system [\#3056](https://github.com/cloudfoundry-incubator/stratos/issues/3056)
- Endpoint login exposes user credentials via query string [\#3160](https://github.com/cloudfoundry-incubator/stratos/issues/3160)
- Don't send registration info in query string [\#3777](https://github.com/cloudfoundry-incubator/stratos/pull/3777)

**Improvements:**

- Add Application Autoscaler UI [\#3455](https://github.com/cloudfoundry-incubator/stratos/pull/3455)
- Quotas: org/space quotas: listing and management [\#3650](https://github.com/cloudfoundry-incubator/stratos/pull/3650)
- Quotas: allow quota to be specified on creation/edit of org/space [\#3593](https://github.com/cloudfoundry-incubator/stratos/pull/3593)
- Refactor setup config [\#3694](https://github.com/cloudfoundry-incubator/stratos/pull/3694)
- Helm Chart: Add imagelist to the helm chart [\#3638](https://github.com/cloudfoundry-incubator/stratos/pull/3638)
- Support separate auth and token endpoints [\#3635](https://github.com/cloudfoundry-incubator/stratos/pull/3635)
- Improve failed connection message for cf & metrics endpoints [\#3600](https://github.com/cloudfoundry-incubator/stratos/pull/3600)
- Handle endpoint types that do no support connect [\#3596](https://github.com/cloudfoundry-incubator/stratos/pull/3596)
- Make disconnected endpoints more obviously different [\#3554](https://github.com/cloudfoundry-incubator/stratos/issues/3554)
- Always build with go modules [\#3589](https://github.com/cloudfoundry-incubator/stratos/pull/3589)
- Don't show cell metrics when they're not available [\#3586](https://github.com/cloudfoundry-incubator/stratos/pull/3586)
- Handle 'no auth' auth type in optional connect step [\#3535](https://github.com/cloudfoundry-incubator/stratos/issues/3535)
- Notifications page: Add a back button [\#3523](https://github.com/cloudfoundry-incubator/stratos/issues/3523)

## 2.4.0

[Full Changelog](https://github.com/cloudfoundry-incubator/stratos/compare/2.3.0...2.4.0)
Expand Down
53 changes: 53 additions & 0 deletions build/tools/changelog.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,53 @@
#!/usr/bin/env node

console.log('Collecting Change Log');

let since = '>=2019-05-03';

const request = require('request-promise-native');
const repo = 'cloudfoundry-incubator/stratos';
const fs = require('fs');

let url = 'https://api.github.com/search/issues?q=state:closed+repo:' + repo + '+updated:' + since;
url = url + '&per_page=100';

const fileName = './log.md';

console.log(url);

let total = -1;
let fetched = 0;
let results = [];

function fetchPage(url, page) {
const pageUrl = url + '&page=' + page;
return request(pageUrl, {
headers: {
'User-Agent': 'Changelog'
},
json: true}).then(data => {
console.log('Fetched page : ' + page);

if (page === 1) {
total = data.total_count;
console.log('Total results : ' + total);
}
fetched += data.items.length;
results = results.concat(data.items);

if (fetched < total) {
return fetchPage(url, page + 1);
}
console.log('Got all data');
});
}

fetchPage(url, 1).then(data => {
fs.writeFileSync(fileName, '# Changes\n');
for(let i = 0; i<results.length;i++) {
const item = results[i];
let line = '- ' + item.title + ' [\\#' + item.number + '](' + item.html_url + ')\n';
fs.appendFileSync(fileName, line);
};

});
Original file line number Diff line number Diff line change
@@ -1,7 +1,12 @@
FROM {{BASE_IMAGE}}
{{#IS_SLE}}
RUN zypper addrepo -G -t yum -c 'http://nginx.org/packages/sles/12' nginx
RUN zypper addrepo -t rpm-md -G -c '{{SMT_INTERNAL_SERVER}}' smt_internal_server
{{/IS_SLE}}
RUN zypper -n ref && \
zypper -n up && \
zypper in -y nginx
zypper in -y nginx apache2-utils

{{#IS_SLE}}
RUN zypper rr smt_internal_server
{{/IS_SLE}}
2 changes: 1 addition & 1 deletion package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "stratos",
"version": "2.4.0",
"version": "2.5.0",
"description": "Stratos Console",
"main": "index.js",
"scripts": {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,9 @@
import { RequestMethod, RequestOptions, URLSearchParams } from '@angular/http';

import { IQuotaDefinition } from '../../../core/src/core/cf-api.types';
import {
QuotaFormValues,
} from '../../../core/src/features/cloud-foundry/quota-definition-form/quota-definition-form.component';
import {
EntityInlineChildAction,
EntityInlineParentAction,
Expand All @@ -16,7 +19,6 @@ import {
} from '../cf-entity-factory';
import { CFStartAction } from './cf-action.types';


export const GET_QUOTA_DEFINITION = '[QuotaDefinition] Get one';
export const GET_QUOTA_DEFINITION_SUCCESS = '[QuotaDefinition] Get one success';
export const GET_QUOTA_DEFINITION_FAILED = '[QuotaDefinition] Get one failed';
Expand Down Expand Up @@ -68,6 +70,30 @@ export const DELETE_SPACE_QUOTA_DEFINITION_FAILED = '[QuotaDefinitions] Delete s
const quotaDefinitionEntitySchema = cfEntityFactory(quotaDefinitionEntityType);
const spaceQuotaEntitySchema = cfEntityFactory(spaceQuotaEntityType);

const UNLIMITED = -1;
function orgSpaceQuotaFormValuesToApiObject(formValues: QuotaFormValues, isOrg = true, orgGuid?: string): IQuotaDefinition {
const res: IQuotaDefinition = {
name: formValues.name,
total_services: formValues.totalServices || UNLIMITED,
total_routes: formValues.totalRoutes || UNLIMITED,
memory_limit: formValues.memoryLimit,
app_task_limit: formValues.appTasksLimit || UNLIMITED,
total_service_keys: formValues.totalServiceKeys || UNLIMITED,
instance_memory_limit: formValues.instanceMemoryLimit || UNLIMITED,
non_basic_services_allowed: formValues.nonBasicServicesAllowed,
total_reserved_route_ports: formValues.totalReservedRoutePorts || UNLIMITED,
app_instance_limit: formValues.appInstanceLimit || UNLIMITED,
};
if (isOrg) {
// Required for org quotas
res.total_private_domains = formValues.totalPrivateDomains || UNLIMITED;
} else if (orgGuid) {
// Required for creating space quota
res.organization_guid = orgGuid;
}
return res;
}

export class GetQuotaDefinitions extends CFStartAction implements PaginatedAction {
constructor(
public paginationKey: string,
Expand Down Expand Up @@ -209,12 +235,12 @@ export class DisassociateSpaceQuota extends CFStartAction implements ICFAction {
}

export class CreateQuotaDefinition extends CFStartAction implements ICFAction {
constructor(public endpointGuid: string, public createQuota: IQuotaDefinition) {
constructor(public endpointGuid: string, public createQuota: QuotaFormValues) {
super();
this.options = new RequestOptions();
this.options.url = `quota_definitions`;
this.options.method = RequestMethod.Post;
this.options.body = createQuota;
this.options.body = orgSpaceQuotaFormValuesToApiObject(createQuota);
this.guid = createQuota.name;
}
actions = [
Expand All @@ -232,12 +258,12 @@ export class UpdateQuotaDefinition extends CFStartAction implements ICFAction {

public static UpdateExistingQuota = 'Updating-Existing-Quota';

constructor(public guid: string, public endpointGuid: string, updateQuota: IQuotaDefinition) {
constructor(public guid: string, public endpointGuid: string, updateQuota: QuotaFormValues) {
super();
this.options = new RequestOptions();
this.options.url = `quota_definitions/${guid}`;
this.options.method = RequestMethod.Put;
this.options.body = updateQuota;
this.options.body = orgSpaceQuotaFormValuesToApiObject(updateQuota);
}
actions = [
UPDATE_QUOTA_DEFINITION,
Expand Down Expand Up @@ -272,12 +298,12 @@ export class DeleteQuotaDefinition extends CFStartAction implements ICFAction {
}

export class CreateSpaceQuotaDefinition extends CFStartAction implements ICFAction {
constructor(public endpointGuid: string, public createQuota: IQuotaDefinition) {
constructor(public endpointGuid: string, orgGuid: string, public createQuota: QuotaFormValues) {
super();
this.options = new RequestOptions();
this.options.url = `space_quota_definitions`;
this.options.method = RequestMethod.Post;
this.options.body = createQuota;
this.options.body = orgSpaceQuotaFormValuesToApiObject(createQuota, false, orgGuid);
this.guid = createQuota.name;
}
actions = [
Expand All @@ -295,12 +321,12 @@ export class UpdateSpaceQuotaDefinition extends CFStartAction implements ICFActi

public static UpdateExistingSpaceQuota = 'Updating-Existing-Space-Quota';

constructor(public guid: string, public endpointGuid: string, updateQuota: IQuotaDefinition) {
constructor(public guid: string, public endpointGuid: string, updateQuota: QuotaFormValues) {
super();
this.options = new RequestOptions();
this.options.url = `space_quota_definitions/${guid}`;
this.options.method = RequestMethod.Put;
this.options.body = updateQuota;
this.options.body = orgSpaceQuotaFormValuesToApiObject(updateQuota, false);
}
actions = [
UPDATE_SPACE_QUOTA_DEFINITION,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -154,7 +154,7 @@ export class CloudFoundrySpaceService {
)
);
this.quotaLink$ = combineLatest(this.quotaDefinition$, this.spaceQuotaDefinition$).pipe(
map(([quota, spaceQuota]) => {
map(([quota, spaceQuota]) => {
if (!spaceQuota) {
return [
'/cloud-foundry',
Expand All @@ -170,12 +170,12 @@ export class CloudFoundrySpaceService {
this.cfGuid,
'organizations',
this.orgGuid,
'space',
'spaces',
this.spaceGuid,
'space-quota'
];
}
)
)
);
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,17 +3,15 @@ import { MatDialog } from '@angular/material';
import { Observable, Subscription } from 'rxjs';
import { map, tap } from 'rxjs/operators';

import {
CloudFoundryEndpointService,
} from '../../../../../../cloud-foundry/src/features/cloud-foundry/services/cloud-foundry-endpoint.service';
import {
UserInviteConfigurationDialogComponent,
} from '../../../../../../cloud-foundry/src/features/cloud-foundry/user-invites/configuration-dialog/user-invite-configuration-dialog.component';
import {
UserInviteService,
} from '../../../../../../cloud-foundry/src/features/cloud-foundry/user-invites/user-invite.service';
import { ICfV2Info } from '../../../../../../core/src/core/cf-api.types';
import { APIResource, EntityInfo } from '../../../../../../store/src/types/api.types';
import { CloudFoundryEndpointService } from '../../../../features/cloud-foundry/services/cloud-foundry-endpoint.service';
import {
UserInviteConfigurationDialogComponent,
} from '../../../../features/cloud-foundry/user-invites/configuration-dialog/user-invite-configuration-dialog.component';

@Component({
selector: 'app-card-cf-info',
Expand Down
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
// tslint:disable:max-line-length
import { CommonModule } from '@angular/common';
import { ApplicationModule, NgModule } from '@angular/core';
import { MaterialDesignFrameworkModule } from 'stratos-angular6-json-schema-form';
Expand All @@ -6,6 +7,9 @@ import { CoreModule } from '../../../../core/src/core/core.module';
import {
TableCellCfCellComponent,
} from '../../../../core/src/shared/components/list/list-types/app-instance/table-cell-cf-cell/table-cell-cf-cell.component';
import {
TableCellQuotaComponent,
} from '../../../../core/src/shared/components/list/list-types/cf-quotas/table-cell-quota/table-cell-quota.component';
import { SharedModule } from '../../../../core/src/shared/shared.module';
import {
AddServiceInstanceBaseStepComponent,
Expand Down Expand Up @@ -127,7 +131,8 @@ import { SelectServiceComponent } from './select-service/select-service.componen
import { ServiceIconComponent } from './service-icon/service-icon.component';
import { ServicePlanPriceComponent } from './service-plan-price/service-plan-price.component';
import { ServicePlanPublicComponent } from './service-plan-public/service-plan-public.component';
import { TableCellQuotaComponent } from '../../../../core/src/shared/components/list/list-types/cf-quotas/table-cell-quota/table-cell-quota.component';

// tslint:enable:max-line-length

@NgModule({
imports: [
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,9 +6,6 @@ import { switchMap } from 'rxjs/operators';
import { CFAppState } from '../../../../../../../cloud-foundry/src/cf-app-state';
import { ApplicationService } from '../../../../../../../cloud-foundry/src/features/applications/application.service';
import { isServiceInstance } from '../../../../../../../cloud-foundry/src/features/cloud-foundry/cf.helpers';
import {
TableCellServiceInstanceTagsComponent,
} from '../../../../../../../cloud-foundry/src/shared/components/list/list-types/cf-spaces-service-instances/table-cell-service-instance-tags/table-cell-service-instance-tags.component';
import { IServiceBinding } from '../../../../../../../core/src/core/cf-api-svc.types';
import { CurrentUserPermissions } from '../../../../../../../core/src/core/current-user-permissions.config';
import { CurrentUserPermissionsService } from '../../../../../../../core/src/core/current-user-permissions.service';
Expand All @@ -20,6 +17,9 @@ import { ListView } from '../../../../../../../store/src/actions/list.actions';
import { RouterNav } from '../../../../../../../store/src/actions/router.actions';
import { APIResource } from '../../../../../../../store/src/types/api.types';
import { BaseCfListConfig } from '../base-cf/base-cf-list-config';
import {
TableCellServiceInstanceTagsComponent,
} from '../cf-spaces-service-instances/table-cell-service-instance-tags/table-cell-service-instance-tags.component';
import { AppServiceBindingCardComponent } from './app-service-binding-card/app-service-binding-card.component';
import { AppServiceBindingDataSource } from './app-service-binding-data-source';

Expand Down
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
// tslint:disable:max-line-length
import { DatePipe } from '@angular/common';
import { Injectable } from '@angular/core';
import { Store } from '@ngrx/store';
Expand All @@ -23,6 +24,7 @@ import { BaseCfListConfig } from '../base-cf/base-cf-list-config';
import { CfCellHealthDataSource, CfCellHealthEntry, CfCellHealthState } from './cf-cell-health-source';

// TODO: Move file to CF package (#3769)
// tslint:enable:max-line-length

@Injectable()
export class CfCellHealthListConfigService extends BaseCfListConfig<CfCellHealthEntry> {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
// tslint:disable:max-line-length
import { Injectable } from '@angular/core';
import { Store } from '@ngrx/store';

Expand All @@ -18,6 +19,8 @@ import { ActiveRouteCfCell } from '../../../../../features/cloud-foundry/cf-page
import { BaseCfListConfig } from '../base-cf/base-cf-list-config';
import { CfCellsDataSource } from './cf-cells-data-source';

// tslint:enable:max-line-length

@Injectable()
export class CfCellsListConfigService extends BaseCfListConfig<IMetricVectorResult<IMetricCell>> {

Expand Down

0 comments on commit a278bdc

Please sign in to comment.