Skip to content

Commit

Permalink
Remove for loop
Browse files Browse the repository at this point in the history
  • Loading branch information
Prince Rachit Sinha committed Jun 30, 2021
1 parent 467a61e commit 687463d
Showing 1 changed file with 3 additions and 7 deletions.
10 changes: 3 additions & 7 deletions .werft/build.ts
Original file line number Diff line number Diff line change
Expand Up @@ -298,14 +298,10 @@ export async function deployToDev(deploymentConfig: DeploymentConfig, workspaceF
try {
if (deploymentConfig.cleanSlateDeployment) {
// re-create namespace
for (let pathToKubeConfig of [""]) {
await cleanStateEnv(pathToKubeConfig);
}
await cleanStateEnv("");

} else {
for (let pathToKubeConfig of [""]) {
createNamespace(pathToKubeConfig, namespace, { slice: 'prep' });
}
createNamespace("", namespace, { slice: 'prep' });
}
// check how this affects further steps
setKubectlContextNamespace(namespace, { slice: 'prep' });
Expand Down Expand Up @@ -398,7 +394,7 @@ export async function deployToDev(deploymentConfig: DeploymentConfig, workspaceF
}

function installGitpodOnK3sWsCluster(commonFlags: string, pathToKubeConfig: string) {
if(!k3sWsCluster){
if (!k3sWsCluster) {
return
}
let flags = commonFlags
Expand Down

0 comments on commit 687463d

Please sign in to comment.