RohanVashisht commited on
Commit
89ae2ca
·
verified ·
1 Parent(s): 0b3e194

Update Dockerfile

Browse files
Files changed (1) hide show
  1. Dockerfile +13 -11
Dockerfile CHANGED
@@ -1,20 +1,22 @@
1
- FROM oven/bun:1.0.30
2
 
3
- RUN apt-get update && apt-get install -y git
 
 
4
 
5
- RUN adduser --disabled-password --gecos "" user
6
- USER user
7
- ENV PATH="/home/user/.bun/bin:$PATH"
8
 
9
  WORKDIR /app
10
 
11
- # Clone the repository
12
- RUN git clone https://github.com/zigistry/database
13
 
14
- COPY --chown=user . .
15
 
16
- RUN bun install
17
 
18
- EXPOSE 7860
 
19
 
20
- CMD ["bun", "./src/index.ts"]
 
 
1
+ FROM debian:bookworm-slim
2
 
3
+ RUN apt-get update && apt-get install -y \
4
+ curl git unzip \
5
+ && rm -rf /var/lib/apt/lists/*
6
 
7
+ RUN curl -fsSL https://bun.sh/install | bash
8
+ ENV PATH="/root/.bun/bin:$PATH"
 
9
 
10
  WORKDIR /app
11
 
12
+ COPY . .
 
13
 
14
+ RUN git clone https://github.com/zigistry/database ./database --depth=1
15
 
16
+ RUN bun install --production
17
 
18
+ ENV PORT=7860
19
+ EXPOSE $PORT
20
 
21
+ # Run your app
22
+ CMD ["bun", "src/index.ts"]