1
0
mirror of https://github.com/sasjs/server.git synced 2025-12-10 19:34:34 +00:00

fix(deploy): user can deploy to same appName with different/same appLoc

This commit is contained in:
Saad Jutt
2022-03-24 00:54:59 +05:00
parent adc5aca0f0
commit 9ace33d783
2 changed files with 50 additions and 11 deletions

View File

@@ -40,17 +40,6 @@ export const publishAppStream = async (
if (!streamServiceName) {
streamServiceName = `AppStreamName${appCount + 1}`
} else {
const alreadyDeployed = process.appStreamConfig[streamServiceName]
if (alreadyDeployed) {
if (alreadyDeployed.appLoc === appLoc) {
// redeploying to same streamServiceName
} else {
// trying to deploy to another existing streamServiceName
// assign new streamServiceName
streamServiceName = `${streamServiceName}-${appCount + 1}`
}
}
}
router.use(`/${streamServiceName}`, express.static(pathToDeployment))