Skip to content

Commit

Permalink
Merge pull request #316 from tmobile/v1.5.1
Browse files Browse the repository at this point in the history
Release v1.6
  • Loading branch information
suryajak authored May 31, 2018
2 parents 9165534 + 394222c commit d94d5f6
Show file tree
Hide file tree
Showing 61 changed files with 7,008 additions and 1,192 deletions.
224 changes: 140 additions & 84 deletions delete-serverless-service-build-pack/Jenkinsfile

Large diffs are not rendered by default.

42 changes: 38 additions & 4 deletions jazz-build-module/service-configuration-data-loader.groovy
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,22 @@ def loadServiceConfigurationData() {
sh "sed -i -- 's/{conf-jenkins-host}/${jenkins_url}/g' ./index.js"
}

if ( (service_name.trim() == "jazz_scm-webhook") ) {
if ( (service_name.trim() == "jazz_deployments") ) {
sh "sed -i -- 's/{conf_stack_prefix}/${config_loader.INSTANCE_PREFIX}/g' ./config/dev-config.json"
sh "sed -i -- 's/{conf_stack_prefix}/${config_loader.INSTANCE_PREFIX}/g' ./config/stg-config.json"
sh "sed -i -- 's/{conf_stack_prefix}/${config_loader.INSTANCE_PREFIX}/g' ./config/prod-config.json"

sh "sed -i -- 's/{jazz_admin}/${config_loader.JAZZ.ADMIN}/g' ./config/dev-config.json"
sh "sed -i -- 's/{jazz_admin}/${config_loader.JAZZ.ADMIN}/g' ./config/stg-config.json"
sh "sed -i -- 's/{jazz_admin}/${config_loader.JAZZ.ADMIN}/g' ./config/prod-config.json"

sh "sed -i -- 's/{jazz_admin_creds}/${config_loader.JAZZ.PASSWD}/g' ./config/dev-config.json"
sh "sed -i -- 's/{jazz_admin_creds}/${config_loader.JAZZ.PASSWD}/g' ./config/stg-config.json"
sh "sed -i -- 's/{jazz_admin_creds}/${config_loader.JAZZ.PASSWD}/g' ./config/prod-config.json"
}

if ((service_name.trim() == "jazz_scm-webhook")) {

sh "sed -i -- 's/{conf-apikey}/${utilModule.getAPIIdForCore(config_loader.AWS.API["DEV"])}/g' ./config/dev-config.json"
sh "sed -i -- 's/{conf-apikey}/${utilModule.getAPIIdForCore(config_loader.AWS.API["STG"])}/g' ./config/stg-config.json"
sh "sed -i -- 's/{conf-apikey}/${utilModule.getAPIIdForCore(config_loader.AWS.API["PROD"])}/g' ./config/prod-config.json"
Expand All @@ -65,7 +80,7 @@ def loadServiceConfigurationData() {

}

if ( (service_name.trim() == "jazz_environments") ) {
if ((service_name.trim() == "jazz_environments")) {
sh "sed -i -- 's/{conf-apikey}/${utilModule.getAPIIdForCore(config_loader.AWS.API["DEV"])}/g' ./config/dev-config.json"
sh "sed -i -- 's/{conf-apikey}/${utilModule.getAPIIdForCore(config_loader.AWS.API["STG"])}/g' ./config/stg-config.json"
sh "sed -i -- 's/{conf-apikey}/${utilModule.getAPIIdForCore(config_loader.AWS.API["PROD"])}/g' ./config/prod-config.json"
Expand Down Expand Up @@ -101,6 +116,24 @@ def loadServiceConfigurationData() {
sh "sed -i -- 's/{jazz_admin_creds}/${config_loader.JAZZ.PASSWD}/g' ./config/prod-config.json"
}

if ((service_name.trim() == "jazz_deployments-event-handler")) {
sh "sed -i -- 's/{conf-apikey}/${utilModule.getAPIIdForCore(config_loader.AWS.API["DEV"])}/g' ./config/dev-config.json"
sh "sed -i -- 's/{conf-apikey}/${utilModule.getAPIIdForCore(config_loader.AWS.API["STG"])}/g' ./config/stg-config.json"
sh "sed -i -- 's/{conf-apikey}/${utilModule.getAPIIdForCore(config_loader.AWS.API["PROD"])}/g' ./config/prod-config.json"

sh "sed -i -- 's/{conf-region}/${region}/g' ./config/dev-config.json"
sh "sed -i -- 's/{conf-region}/${region}/g' ./config/stg-config.json"
sh "sed -i -- 's/{conf-region}/${region}/g' ./config/prod-config.json"

sh "sed -i -- 's/{jazz_admin}/${config_loader.JAZZ.ADMIN}/g' ./config/dev-config.json"
sh "sed -i -- 's/{jazz_admin}/${config_loader.JAZZ.ADMIN}/g' ./config/stg-config.json"
sh "sed -i -- 's/{jazz_admin}/${config_loader.JAZZ.ADMIN}/g' ./config/prod-config.json"

sh "sed -i -- 's/{jazz_admin_creds}/${config_loader.JAZZ.PASSWD}/g' ./config/dev-config.json"
sh "sed -i -- 's/{jazz_admin_creds}/${config_loader.JAZZ.PASSWD}/g' ./config/stg-config.json"
sh "sed -i -- 's/{jazz_admin_creds}/${config_loader.JAZZ.PASSWD}/g' ./config/prod-config.json"
}

if ((service_name.trim() == "jazz_events")) {
sh "sed -i -- 's/{conf_stack_prefix}/${config_loader.INSTANCE_PREFIX}/g' ./config/dev-config.json"
sh "sed -i -- 's/{conf_stack_prefix}/${config_loader.INSTANCE_PREFIX}/g' ./config/stg-config.json"
Expand Down Expand Up @@ -180,7 +213,7 @@ def loadServiceConfigurationData() {
sh "sed -i -- 's/{jazz_admin_creds}/${config_loader.JAZZ.PASSWD}/g' ./config/prod-config.json"
}

if ((service_name.trim() == "jazz_delete-serverless-service") || (service_name.trim() == "jazz_create-serverless-service")) {
if ((service_name.trim() == "jazz_delete-serverless-service") || (service_name.trim() == "jazz_create-serverless-service") || (service_name.trim() == "jazz_deployments")) {
sh "sed -i -- 's/{conf-jenkins-host}/${jenkins_url}/g' ./config/dev-config.json"
sh "sed -i -- 's/{conf-jenkins-host}/${jenkins_url}/g' ./config/stg-config.json"
sh "sed -i -- 's/{conf-jenkins-host}/${jenkins_url}/g' ./config/prod-config.json"
Expand Down Expand Up @@ -305,7 +338,8 @@ def setUtilModule(util){
utilModule = util
}
def setKinesisStream(config){
if ((config['service'].trim() == "services-handler") || (config['service'].trim() == "events-handler") || (config['service'] == "environment-event-handler")) {
if ((config['service'].trim() == "services-handler") || (config['service'].trim() == "events-handler") ||
(config['service'] == "environment-event-handler") || (config['service'] == "deployments-event-handler")) {
def function_name = "${config_loader.INSTANCE_PREFIX}-${config['domain']}-${config['service']}-${current_environment}"
def event_source_list = sh(
script: "aws lambda list-event-source-mappings --query \"EventSourceMappings[?contains(FunctionArn, '$function_name')]\" --region \"$region\"",
Expand Down
12 changes: 11 additions & 1 deletion jazz-ui/.gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -30,4 +30,14 @@
*/target/
.nyc_output/
npm-debug.log
*/package-lock.json
*/package-lock.json
testem.log
/typings

# e2e
/e2e/*.js
/e2e/*.map

#System Files
.DS_Store
Thumbs.db
17 changes: 13 additions & 4 deletions jazz-ui/Jenkinsfile_Platform
Original file line number Diff line number Diff line change
Expand Up @@ -74,16 +74,25 @@ node () {
dir('jazz-ui') {
checkout([$class: 'GitSCM', branches: [[name: '*/master']], doGenerateSubmoduleConfigurations: false, extensions: [], submoduleCfg: [], userRemoteConfigs: [[credentialsId: config_loader.REPOSITORY.CREDENTIAL_ID, url: scmModule.getCoreRepoCloneUrl("jazz-ui")]]])
def jazz_prod_api_id = utilModule.getAPIIdForCore(config_loader.AWS.API["PROD"])


if(config_loader.UI_CONFIG.service_tabs.overview) sh "sed -i 's/{overview}/overview/g' ./src/environments/environment.oss.ts";
if(config_loader.UI_CONFIG.service_tabs.access_control) sh "sed -i 's/{access control}/access control/g' ./src/environments/environment.oss.ts";
if(config_loader.UI_CONFIG.service_tabs.metrics) sh "sed -i 's/{metrics}/metrics/g' ./src/environments/environment.oss.ts";
if(config_loader.UI_CONFIG.service_tabs.cost) sh "sed -i 's/{cost}/cost/g' ./src/environments/environment.oss.ts";
if(config_loader.UI_CONFIG.service_tabs.logs) sh "sed -i 's/{logs}/logs/g' ./src/environments/environment.oss.ts";
if(config_loader.UI_CONFIG.environment_tabs.overview) sh "sed -i 's/{env_overview}/overview/g' ./src/environments/environment.oss.ts";
if(config_loader.UI_CONFIG.environment_tabs.deployments) sh "sed -i 's/{deployments}/deployments/g' ./src/environments/environment.oss.ts";
if(config_loader.UI_CONFIG.environment_tabs.code_quality) sh "sed -i 's/{code quality}/code quality/g' ./src/environments/environment.oss.ts";
if(config_loader.UI_CONFIG.environment_tabs.assets) sh "sed -i 's/{assets}/assets/g' ./src/environments/environment.oss.ts";
if(config_loader.UI_CONFIG.environment_tabs.logs) sh "sed -i 's/{env_logs}/logs/g' ./src/environments/environment.oss.ts";

sh "sed -i 's/{api_doc_name}/${config_loader.AWS.S3.API_DOC}/g' ./src/environments/environment.oss.ts"
sh "sed -i 's/{API_GATEWAY_KEY_PROD}/${jazz_prod_api_id}/g' ./src/environments/environment.oss.ts"
sh "sed -i 's/{inst_region}/${config_loader.AWS.REGION}/g' ./src/environments/environment.oss.ts"
sh "sed -i 's/{multi_env}/${config_loader.UI_CONFIG.feature.multi_env}/g' ./src/environments/environment.oss.ts"
sh "sed -i 's/{service_tabs}/${config_loader.UI_CONFIG.service_tabs}/g' ./src/environments/environment.oss.ts"
sh "sed -i 's/{environment_tabs}/${config_loader.UI_CONFIG.environment_tabs}/g' ./src/environments/environment.oss.ts"


def envFile = readFile('./src/environments/environment.oss.ts');
echo "displaying env file :"
echo "$envFile";
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ import { Filter } from '../../secondary-components/jazz-table/jazz-filter';
import { Sort } from '../../secondary-components/jazz-table/jazz-table-sort';
import { ToasterService } from 'angular2-toaster';
declare var $:any;
import { environment } from './../../../environments/environment.internal';
import { environment } from './../../../environments/environment';
import { environment as env_internal } from './../../../environments/environment.internal';


Expand Down Expand Up @@ -457,8 +457,7 @@ export class EnvDeploymentsSectionComponent implements OnInit {
window.open(url, '_blank');
}

ngOnInit() {

ngOnInit() {
}

paginatePage(currentlyActivePage){
Expand Down Expand Up @@ -571,7 +570,7 @@ export class EnvDeploymentsSectionComponent implements OnInit {
this.paginatePage(this.currentlyActive);
}

ngOnChanges(x:any) {
ngOnChanges(x:any) {
this.envObj = this.cache.get('currentEnv');
this.status_val = parseInt(status[this.envObj.status]);

Expand Down Expand Up @@ -619,13 +618,11 @@ toast_pop(error,oops,errorMessage)

rebuild(){
this.rowclick = false;
this.http.post('/jazz/deployments/'+this.rebuild_id+'/re-build').subscribe(
var rebuild_url = '/jazz/deployments/';
this.http.post(rebuild_url+this.rebuild_id+'/re-build').subscribe(
(response) => {

let successMessage = this.toastmessage.successMessage(response, "retryDeploy");

this.toast_pop('success',"",successMessage+this.service.name);

this.toast_pop('success',"",successMessage+this.service.name);
},
(error) => {
let errorMessage = this.toastmessage.errorMessage(error, "updateObj");
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@
<div class="view-hdr-wrp">
<jazz-header class="hide-for-mobile"></jazz-header>
</div>
<side-tile-fixed [inputData]="recentActivities" [actState]='mobSecState'></side-tile-fixed>

<div class="view-container" [class.translate-for-mob]="mobSecState == 2">
<div class="services-content-wrp">
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -621,6 +621,7 @@ export class ServiceOverviewComponent implements OnInit {
friendly_name: this.friendlist
}
}

if (this.Environments.length == 0) {
this.noSubEnv = true;
}
Expand All @@ -632,6 +633,8 @@ export class ServiceOverviewComponent implements OnInit {
}

this.cache.set('envList', this.list);


}

sortEnvArr() {
Expand Down
2 changes: 0 additions & 2 deletions jazz-ui/src/app/pages/services/services.component.html
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,6 @@
<div class="view-hdr-wrp">
<jazz-header class="hide-for-mobile"></jazz-header>
</div>
<side-tile-fixed [inputData]="recentActivities" [actState]='mobSecState'></side-tile-fixed>

<div class="view-container" [class.translate-for-mob]="mobSecState == 2">
<div class="services-content-wrp">
<!-- <span class="reduxC" *ngIf='service.status == "deletion completed"'></span>
Expand Down
3 changes: 1 addition & 2 deletions jazz-ui/src/app/pages/services/services.component.scss
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
@import './../../../main-styles';
.services-content-wrp {
width: 80%; //fallback
width: calc(100% - 300px);
width:100%;
display: inline-block;
padding: 0 37px 0px 37px;
float: left; // min-height: 100vh;
Expand Down
Loading

0 comments on commit d94d5f6

Please sign in to comment.