@@ -240,8 +240,8 @@ export async function deploy(options: SWACLIConfig) {
240240 DEPLOYMENT_TOKEN : deploymentToken ,
241241 // /!\ Static site client doesn't use OUTPUT_LOCATION at all if SKIP_APP_BUILD is set,
242242 // so you need to provide the output path as the app location
243- APP_LOCATION : userWorkflowConfig ?. outputLocation ,
244- // OUTPUT_LOCATION: outputLocation,
243+ APP_LOCATION : userWorkflowConfig ?. appLocation ,
244+ OUTPUT_LOCATION : userWorkflowConfig ?. outputLocation ,
245245 API_LOCATION : userWorkflowConfig ?. apiLocation ,
246246 DATA_API_LOCATION : userWorkflowConfig ?. dataApiLocation ,
247247 // If config file is not in output location, we need to tell where to find it
@@ -271,13 +271,15 @@ export async function deploy(options: SWACLIConfig) {
271271 logger . silly ( `Deploying using ${ cliEnv . SWA_CLI_DEPLOY_BINARY } ` ) ;
272272 logger . silly ( `Deploying using the following options:` ) ;
273273 logger . silly ( { env : { ...cliEnv , ...deployClientEnv } } ) ;
274+ logger . silly ( `StaticSiteClient working directory: ${ path . dirname ( userWorkflowConfig ?. appLocation ! ) } ` ) ;
274275
275276 spinner . start ( `Preparing deployment. Please wait...` ) ;
276277
277278 const child = spawn ( binary , [ ] , {
278279 env : {
279280 ...swaCLIEnv ( cliEnv , deployClientEnv ) ,
280281 } ,
282+ cwd : path . dirname ( userWorkflowConfig ?. appLocation ! ) ,
281283 } ) ;
282284
283285 let projectUrl = "" ;
0 commit comments