mirror of
https://github.com/cupcakearmy/cryptgeon.git
synced 2024-12-22 08:16:28 +00:00
32 lines
487 B
Docker
32 lines
487 B
Docker
# Frontend
|
|
FROM node:16-alpine as CLIENT
|
|
|
|
WORKDIR /tmp
|
|
COPY ./frontend ./
|
|
|
|
RUN npm install -g pnpm
|
|
RUN pnpm install
|
|
RUN pnpm run build
|
|
|
|
# Backend
|
|
FROM rust:1.59-alpine as RUST
|
|
|
|
WORKDIR /tmp
|
|
RUN apk add libc-dev openssl-dev alpine-sdk
|
|
COPY ./backend ./
|
|
|
|
RUN cargo build --release
|
|
|
|
# Server
|
|
FROM alpine
|
|
|
|
WORKDIR /app
|
|
COPY --from=RUST /tmp/target/release/cryptgeon .
|
|
COPY --from=CLIENT /tmp/build ./frontend/build
|
|
|
|
ENV MEMCACHE=memcached:11211
|
|
|
|
EXPOSE 5000
|
|
|
|
ENTRYPOINT [ "/app/cryptgeon" ]
|