Skip to content

Commit a237ba1

Browse files
committed
replace deprecated deno cache with deno install in docker examples
1 parent e086970 commit a237ba1

File tree

1 file changed

+4
-3
lines changed

1 file changed

+4
-3
lines changed

runtime/reference/docker.md

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -19,8 +19,8 @@ WORKDIR /app
1919
# Copy source
2020
COPY . .
2121

22-
# Compile the main app
23-
RUN deno cache main.ts
22+
# Install dependencies (use just `deno install` if deno.json has imports)
23+
RUN deno install --entrypoint main.ts
2424

2525
# Run the app
2626
CMD ["deno", "run", "--allow-net", "main.ts"]
@@ -37,7 +37,8 @@ For smaller production images:
3737
FROM denoland/deno:latest AS builder
3838
WORKDIR /app
3939
COPY . .
40-
RUN deno cache main.ts
40+
# Install dependencies (use just `deno install` if deno.json has imports)
41+
RUN deno install --entrypoint main.ts
4142

4243
# Production stage
4344
FROM denoland/deno:latest

0 commit comments

Comments
 (0)