Browse Source

chore(create): Add pause after populate step

Another attempt to resolve the issues mentioned in the previous commit.
Michael Bromley 5 years ago
parent
commit
4c07febc04
1 changed files with 2 additions and 0 deletions
  1. 2 0
      packages/create/src/create-vendure-app.ts

+ 2 - 0
packages/create/src/create-vendure-app.ts

@@ -248,6 +248,8 @@ async function createApp(
                     } else {
                         app = await populate(bootstrapFn, initialDataPath);
                     }
+                    // Pause to ensure the worker jobs have time to complete.
+                    await new Promise((resolve) => setTimeout(resolve, isCi ? 10000 : 2000));
                     await app.close();
                 } catch (e) {
                     console.log(e);