@@ -103,26 +103,26 @@ export const JoinCommand = command({
103103 args : JoinArgs ,
104104 async handler ( args ) {
105105 const logger = getLogger ( this , args , 'cli-vector' ) ;
106- const outputPath = `tmp/join/` ;
106+ const outputPath = `/ tmp/join/` ;
107107 const tileMatrix = TileMatrixSets . find ( args . tileMatrix ) ;
108108 if ( tileMatrix == null ) throw new Error ( `Tile matrix ${ args . tileMatrix } is not supported` ) ;
109109 const bucketPath = new URL ( `vector/${ tileMatrix . projection . code } /` , args . target ) ;
110110 const filePaths = await download ( args . fromFile , outputPath , logger ) ;
111111
112112 // Mbtiles output path to be string type path to avoid issues with tippecanoe and better-sqlite3
113- const outputMbtiles = `${ outputPath } / ${ args . filename } .mbtiles` ;
113+ const outputMbtiles = fsa . toUrl ( `${ outputPath } ${ args . filename } .mbtiles` ) ;
114114 logger . info ( { files : filePaths . length , outputMbtiles } , 'JoinMbtiles: Start' ) ;
115- await tileJoin ( filePaths , outputMbtiles , logger ) ;
115+ await tileJoin ( filePaths , outputMbtiles . pathname , logger ) ;
116116 logger . info ( { files : filePaths . length , outputMbtiles } , 'JoinMbtiles: End' ) ;
117117
118118 const outputCotar = fsa . toUrl ( `${ outputPath } /${ args . filename } .tar.co` ) ;
119119 logger . info ( { mbtiles : outputMbtiles , outputCotar } , 'ToTartTiles: Start' ) ;
120- await toTarTiles ( outputMbtiles , outputCotar , logger ) ;
120+ await toTarTiles ( outputMbtiles . pathname , outputCotar . pathname , logger ) ;
121121 logger . info ( { mbtiles : outputMbtiles , outputCotar } , 'ToTartTiles: End' ) ;
122122
123123 const outputIndex = fsa . toUrl ( `${ outputPath } /${ args . filename } .tar.index` ) ;
124124 logger . info ( { cotar : outputCotar , outputIndex } , 'toTarIndex: Start' ) ;
125- await toTarIndex ( outputCotar , outputIndex , logger ) ;
125+ await toTarIndex ( outputCotar . pathname , outputIndex . pathname , logger ) ;
126126 logger . info ( { cotar : outputCotar , outputIndex } , 'toTarIndex: End' ) ;
127127
128128 logger . info ( { target : bucketPath , tileMatrix : tileMatrix . identifier } , 'CreateStac: Start' ) ;
@@ -131,7 +131,7 @@ export const JoinCommand = command({
131131
132132 // Upload output to s3
133133 logger . info ( { target : bucketPath , tileMatrix : tileMatrix . identifier } , 'Upload: Start' ) ;
134- await upload ( fsa . toUrl ( outputMbtiles ) , bucketPath , logger ) ;
134+ await upload ( outputMbtiles , bucketPath , logger ) ;
135135 await upload ( outputCotar , bucketPath , logger ) ;
136136 await upload ( outputIndex , bucketPath , logger ) ;
137137 // Upload stac Files
0 commit comments