diff --git a/keynotes.app/.dockerignore b/keynotes.app/.dockerignore new file mode 100644 index 0000000..f965aed --- /dev/null +++ b/keynotes.app/.dockerignore @@ -0,0 +1,15 @@ +node_modules +Dockerfile* +docker-compose* +.dockerignore +.git +.gitignore +README.md +LICENSE +.vscode +Makefile +helm-charts +.env +.editorconfig +.idea +coverage* diff --git a/keynotes.app/Dockerfile b/keynotes.app/Dockerfile new file mode 100644 index 0000000..d0631b9 --- /dev/null +++ b/keynotes.app/Dockerfile @@ -0,0 +1,31 @@ +FROM oven/bun:1 AS base +WORKDIR /usr/src/app + +# install dependencies into temp directory +# this will cache them and speed up future builds +FROM base AS install +RUN mkdir -p /temp/dev +COPY package.json bun.lock /temp/dev/ +RUN cd /temp/dev && bun install --frozen-lockfile + +# copy node_modules from temp directory +# then copy all (non-ignored) project files into the image +FROM base AS prerelease +COPY --from=install /temp/dev/node_modules node_modules +COPY . . + +# [optional] tests & build +ENV NODE_ENV=production +RUN bun test +RUN bun run build + +# copy production dependencies and source code into final image +FROM base AS release +COPY --from=install /temp/prod/node_modules node_modules +COPY --from=prerelease /usr/src/app/app.js . +COPY --from=prerelease /usr/src/app/package.json . + +# run the app +USER bun +EXPOSE 3000/tcp +ENTRYPOINT [ "bun", "run", "app.js" ] diff --git a/keynotes.app/public/css/style.css b/keynotes.app/public/css/style.css index dd43075..4e11935 100644 --- a/keynotes.app/public/css/style.css +++ b/keynotes.app/public/css/style.css @@ -417,7 +417,7 @@ footer { background: var(--100-blue); border: 2px solid black; width: 100%; - max-width: 150px; + /*max-width: 150px;*/ border-radius: var(--border-radius-sm); z-index: 1; }