Skip to content

Commit

Permalink
fart fart fart
Browse files Browse the repository at this point in the history
  • Loading branch information
untitaker committed Oct 20, 2024
1 parent db0b60c commit 53cfb49
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 3 deletions.
1 change: 1 addition & 0 deletions .dockerignore
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
/testdata
.git
/node_modules
!/node_modules/htmx.org/dist/htmx.min.js
/build
.env
.envrc
6 changes: 3 additions & 3 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
FROM node:21-alpine3.18 as frontend-builder
FROM node:21-alpine3.20 AS frontend-builder

WORKDIR /app
COPY package-lock.json package.json buildscript.js ./
COPY src ./src/
RUN npm ci
RUN npm run build

FROM rust:1.72-alpine3.18 as builder
FROM rust:1.82-alpine3.20 AS builder

RUN mkdir -p ~/.cargo && \
echo '[registries.crates-io]' > ~/.cargo/config && \
Expand All @@ -26,14 +26,14 @@ WORKDIR /app
COPY Cargo.toml .
COPY Cargo.lock .
RUN cargo build --release && rm -rf src/
RUN strip target/release/mastodon-list-bot

# Copy the source code and run the build again.
# This should only compile the app itself as the
# dependencies were already built above.
COPY . ./
COPY --from=frontend-builder /app/build/ /app/build/
RUN rm ./target/release/deps/mastodon_list_bot* && cargo build --release
RUN strip target/release/mastodon-list-bot

# Our production image starts here, which uses
# the files from the builder image above.
Expand Down

0 comments on commit 53cfb49

Please sign in to comment.