2016-06-28 10:22:53 +08:00
|
|
|
/// <reference path="../../includes.d.ts" />
|
2016-09-28 17:04:00 +08:00
|
|
|
/// <reference path="kubernetesHelpers.d.ts" />
|
2016-06-28 10:22:53 +08:00
|
|
|
declare module Kubernetes {
|
|
|
|
var hostPorts: any[];
|
|
|
|
/**
|
|
|
|
* Sorts the the ip field
|
|
|
|
*
|
|
|
|
* @param ip the ip such as '10.1.2.13'
|
|
|
|
* @returns {any}
|
|
|
|
*/
|
|
|
|
function sortByPodIp(ip: any): any;
|
|
|
|
function ramdomPort(): number;
|
|
|
|
function getRandomString(len: number): string;
|
|
|
|
class resourceRCTemplate {
|
|
|
|
image: string;
|
|
|
|
names: string[];
|
|
|
|
createRC(Obj: any): {
|
|
|
|
"apiVersion": string;
|
|
|
|
"kind": string;
|
|
|
|
"metadata": {
|
|
|
|
"name": any;
|
|
|
|
"labels": {
|
|
|
|
"style": string;
|
|
|
|
"status": string;
|
2016-06-30 20:12:32 +08:00
|
|
|
"isExtract": string;
|
|
|
|
"isTarget": any;
|
2016-06-28 10:22:53 +08:00
|
|
|
};
|
2016-09-03 15:03:40 +08:00
|
|
|
"annotations": any;
|
2016-06-28 10:22:53 +08:00
|
|
|
};
|
|
|
|
"spec": {
|
|
|
|
replicas: any;
|
|
|
|
"template": {
|
|
|
|
"metadata": {
|
|
|
|
"labels": any;
|
|
|
|
};
|
|
|
|
"spec": {
|
|
|
|
"terminationGracePeriodSeconds": number;
|
|
|
|
"containers": any[];
|
|
|
|
"volumes": any[];
|
|
|
|
};
|
|
|
|
};
|
|
|
|
};
|
|
|
|
};
|
|
|
|
createVolumeMounts(): any[];
|
|
|
|
createVolumes(rootPath: string): any[];
|
|
|
|
createContainers(Obj: any): any[];
|
|
|
|
createTemplate(Obj: any): {
|
|
|
|
"metadata": {
|
|
|
|
"labels": any;
|
|
|
|
};
|
|
|
|
"spec": {
|
|
|
|
"terminationGracePeriodSeconds": number;
|
|
|
|
"containers": any[];
|
|
|
|
"volumes": any[];
|
|
|
|
};
|
|
|
|
};
|
|
|
|
}
|
|
|
|
function labelToChinese(labels: any): {};
|
2016-06-30 20:12:32 +08:00
|
|
|
function findSameNameReplicationControllers(replicationControllers: any, name: any): any;
|
|
|
|
function isFilterRC(rc: any): boolean;
|
|
|
|
function isInclude(rcs: any, rc: any): boolean;
|
|
|
|
function labelChangeToChines(value: string, key: string): string;
|
2016-09-28 17:04:00 +08:00
|
|
|
function checkForMigration(replicationControllers: Array<KubePod>, selectItem: Array<any>): any[];
|
2016-09-30 11:20:11 +08:00
|
|
|
function checkForExit(replicationControllers: Array<KubePod>, selectItem: any): boolean;
|
2016-09-28 17:04:00 +08:00
|
|
|
function checkForCreateOracle(transferTasks: Array<any>, selectItems: Array<any>): any[];
|
|
|
|
/**
|
|
|
|
|
|
|
|
**/
|
|
|
|
function checkForExtract(replicationControllers: Array<any>): any[];
|
2016-06-28 10:22:53 +08:00
|
|
|
}
|