Skip to content
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
5 changes: 2 additions & 3 deletions .dockerignore
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,8 @@
frontend/node_modules
frontend/dist

# Ignore debug build artifacts but allow release artifacts
**/target/debug
!**/target/release
# Ignore build artifacts
**/target

# Rust/Cargo related
**/Cargo.lock
Expand Down
13 changes: 11 additions & 2 deletions Dockerfile.backend
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,17 @@ RUN apt-get update && apt-get install -y \
&& rm -rf /var/lib/apt/lists/*

WORKDIR /app
COPY . .
RUN cargo build --release

# cache dependencies
COPY Cargo.toml Cargo.lock ./
RUN mkdir src && echo "fn main() {}" > src/main.rs \
&& cargo build --release --locked \
&& rm -r src

COPY src ./src
COPY migrations ./migrations
COPY diesel.toml ./
RUN cargo build --release --locked

FROM debian:buster-slim

Expand Down
10 changes: 8 additions & 2 deletions Dockerfile.worker
Original file line number Diff line number Diff line change
Expand Up @@ -9,11 +9,17 @@ RUN apt-get update && apt-get install -y \

WORKDIR /app

# Copy the worker application code
# cache dependencies for the worker
COPY worker_app/Cargo.toml ./worker_app/
RUN mkdir -p worker_app/src && echo "fn main() {}" > worker_app/src/main.rs \
&& cd worker_app && cargo build --release --locked \
&& rm -r src

# Copy the worker application source
COPY worker_app /app/worker_app

# Build the worker application
RUN cd worker_app && cargo build --release
RUN cd worker_app && cargo build --release --locked

# Install FluentCLI
RUN cargo install --force --git https://github.com/njfio/fluent_cli --branch v.0.5.5-feature-docker-image fluent
Expand Down
16 changes: 5 additions & 11 deletions frontend/Dockerfile.frontend
Original file line number Diff line number Diff line change
Expand Up @@ -6,17 +6,11 @@ COPY package*.json ./

ENV PUPPETEER_SKIP_DOWNLOAD=true

# Clear npm cache
RUN npm cache clean --force

# Install dependencies
RUN npm ci

# Install Vuex (latest version compatible with Vue 3)
RUN npm install vuex@4

# Install dev dependencies including @types/node
RUN npm install --save-dev @types/node
# Clear npm cache and install dependencies
RUN npm cache clean --force \
&& npm ci \
&& npm install vuex@4 \
&& npm install --save-dev @types/node

# Copy all project files
COPY . .
Expand Down