132
132
* JS script for executing actions with the newly cloned environment.
133
133
* The script is subscribed on the onAfterClone event and will be executed after old environment cloning.
134
134
* /
135
-
136
135
var APPID = hivext.local.getParam("TARGET_APPID"),
137
136
CLONED_ENV_APPID = "${event.response.env.appid}", // placeholder for the cloned environment AppID
138
137
@@ -143,8 +142,7 @@ var APPID = hivext.local.getParam("TARGET_APPID"),
143
142
NODE_TYPE_CP = "tomcat7", // keyword of the compute node's software stack.
144
143
NODE_TYPE_DB = "mysql5", // keyword of the DB node's software stack
145
144
146
- HN_GROUP_PROFIT_BRICKS = "pbricks-de", // identifier of the hardware node group a new environment should be migrated to
147
- HN_GROUP_DEFAULT = "default_hn_group"; // second hardware node group's identifier
145
+ HN_GROUP_PROFIT_BRICKS = "pbricks-de"; // second hardware node group's identifier
148
146
149
147
/**
150
148
* Adjust application settings according to a new database connection string
@@ -178,13 +176,8 @@ return jelastic.env.file.ReplaceInBody(CLONED_ENV_APPID, session, APP_INDEX_FILE
178
176
* @returns {Response}
179
177
* /
180
178
function migrateEnv(oClonedEnvInfo) {
181
- var sHardwareNodeGroup;
182
-
183
- // get current environment hardware node group from environment meta information
184
- sHardwareNodeGroup = oClonedEnvInfo.env.hardwareNodeGroup;
185
-
186
179
// migrate environment API to another hardware node group
187
- return jelastic.env.control.Migrate(CLONED_ENV_APPID, session, sHardwareNodeGroup , true);
180
+ return jelastic.env.control.Migrate(CLONED_ENV_APPID, session, HN_GROUP_PROFIT_BRICKS , true);
188
181
}
189
182
190
183
/**
0 commit comments