update dockerfile

This commit is contained in:
Fran Jurmanović
2024-04-17 20:39:46 +02:00
parent e56f0883cf
commit 9ecfdef62b
3 changed files with 8 additions and 5 deletions

BIN
bun.lockb

Binary file not shown.

View File

@@ -1,17 +1,20 @@
# Use oven/bun as parent image # Use oven/bun as parent image
FROM oven/bun:latest FROM oven/bun:1.0.27
# Change the working directory on the Docker image to /app # Change the working directory on the Docker image to /app
WORKDIR /app WORKDIR /app
# Copy package.json and package-lock.json to the /app directory # Copy package.json and package-lock.json to the /app directory
COPY . . COPY package.json ./
COPY bun.lockb ./
COPY src ./src
COPY tsconfig.json ./
# Install dependencies # Install dependencies
RUN bun install RUN bun install --frozen-lockfile
# Expose application port # Expose application port
EXPOSE 3000 EXPOSE 3000
# Start the application # Start the application
CMD bun start CMD ["bun", "start"]

View File

@@ -3,7 +3,7 @@
"version": "2.0.6", "version": "2.0.6",
"main": "src/app.ts", "main": "src/app.ts",
"scripts": { "scripts": {
"start": "bun src/app.ts" "start": "bun run src/app.ts"
}, },
"author": "Fran Jurmanović <fjurma12@outlook.com>", "author": "Fran Jurmanović <fjurma12@outlook.com>",
"license": "MIT", "license": "MIT",