Skip to content

Commit

Permalink
refactor: 优化打包体积
Browse files Browse the repository at this point in the history
  • Loading branch information
ikxin committed Jun 28, 2023
1 parent 2678b18 commit 8801b15
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 3 deletions.
8 changes: 5 additions & 3 deletions packages/kms-tools-bun/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -7,10 +7,12 @@ FROM ubuntu:latest
COPY --from=build /root/.bun/bin/bun /usr/local/bin
COPY . /root/web

RUN cd /root/web && bun install
# RUN cd /root/web && bun install

EXPOSE 8080

WORKDIR /root/web
# WORKDIR /root/web

CMD [ "bun", "run", "src/index.ts" ]
# CMD [ "bun", "run", "src/index.ts" ]

ENTRYPOINT [ "/root/web/entrypoint.sh" ]
7 changes: 7 additions & 0 deletions packages/kms-tools-bun/entrypoint.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
#!/bin/bash

cd /root/web

bun install

bun run src/index.ts

0 comments on commit 8801b15

Please sign in to comment.