Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix docker build #68

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 5 additions & 5 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

# Adjust NODE_VERSION as desired
ARG NODE_VERSION=21.7.1
FROM node:${NODE_VERSION}-slim as base
FROM node:${NODE_VERSION}-slim AS base

LABEL fly_launch_runtime="Next.js"

Expand All @@ -14,18 +14,18 @@ ENV NODE_ENV="production"


# Throw-away build stage to reduce size of final image
FROM base as build
FROM base AS build

# Install packages needed to build node modules
RUN apt-get update -qq && \
apt-get install --no-install-recommends -y build-essential node-gyp pkg-config python-is-python3

# Install node modules
COPY --link package-lock.json package.json ./
RUN npm ci --include=dev
COPY package-lock.json package.json ./
RUN npm install --include dev && npm install --include=optional sharp

# Copy application code
COPY --link . .
COPY . .

# Build application
RUN npm run build
Expand Down
15 changes: 7 additions & 8 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -31,19 +31,18 @@
"resend": "^3.2.0",
"sharp": "^0.33.2",
"tailwind-merge": "^2.2.2",
"tailwindcss-animate": "^1.0.7"
},
"devDependencies": {
"tailwindcss-animate": "^1.0.7",
"postcss": "^8.4.38",
"tailwindcss": "^3.4.1",
"autoprefixer": "^10.4.19",
"@flydotio/dockerfile": "^0.5.2",
"@types/fluent-ffmpeg": "^2.1.24",
"@types/node": "^20",
"@types/react": "^18",
"@types/react-dom": "^18",
"autoprefixer": "^10.4.19",
"eslint": "^8",
"eslint-config-next": "14.1.0",
"postcss": "^8.4.38",
"tailwindcss": "^3.4.1",
"typescript": "^5"
}
}
},
"devDependencies": {}
}