From d1b04ba6490419bbb79aca1d7571a2c252ae3aa1 Mon Sep 17 00:00:00 2001 From: Yi-Jyun Pan Date: Mon, 11 Sep 2023 01:34:09 +0800 Subject: [PATCH] test(planner/nodejs): Update snapshot --- .../nodejs/__snapshots__/template_test.snap | 27 +++++++++++++++++++ 1 file changed, 27 insertions(+) diff --git a/internal/nodejs/__snapshots__/template_test.snap b/internal/nodejs/__snapshots__/template_test.snap index 948829bc..8b8688fc 100755 --- a/internal/nodejs/__snapshots__/template_test.snap +++ b/internal/nodejs/__snapshots__/template_test.snap @@ -135,4 +135,31 @@ RUN echo "\ EXPOSE 8080 +--- + +[TestTemplate_BuildCmd_Bun - 1] +# Install bun if we need it +FROM oven/bun:1.0 as bun-runtime +FROM node:18 as build + +ENV PORT=8080 +WORKDIR /src +# Copy the bun binary from the bun-runtime stage directly. +# A bit hacky but it works. +COPY --from=bun-runtime /usr/local/bin/bun /usr/local/bin +COPY --from=bun-runtime /usr/local/bin/bunx /usr/local/bin + +RUN corepack enable && corepack prepare --all +COPY . . + +RUN bun install + +# Build if we can build it + + + +EXPOSE 8080 +CMD bun start main.ts + + ---