forked from Deuxfleurs/infrastructure
WIP plume container
This commit is contained in:
parent
fcbb788de6
commit
25ec221248
3 changed files with 29 additions and 4 deletions
|
@ -1,9 +1,7 @@
|
||||||
FROM debian:bullseye-slim as builder
|
FROM rust:1.47.0-slim-buster as builder
|
||||||
|
|
||||||
RUN apt-get update && \
|
RUN apt-get update && \
|
||||||
apt-get install -y \
|
apt-get install -y \
|
||||||
rustc \
|
|
||||||
cargo \
|
|
||||||
pkg-config \
|
pkg-config \
|
||||||
git \
|
git \
|
||||||
curl \
|
curl \
|
||||||
|
@ -32,8 +30,27 @@ RUN cargo install diesel_cli --no-default-features --features postgres --version
|
||||||
RUN cargo install cargo-web
|
RUN cargo install cargo-web
|
||||||
RUN cargo web deploy -p plume-front --release
|
RUN cargo web deploy -p plume-front --release
|
||||||
# backend
|
# backend
|
||||||
RUN cargo install --no-default-features --features postgres -f
|
RUN cargo install --no-default-features --features postgres -f --path .
|
||||||
# cli
|
# cli
|
||||||
RUN cargo install --no-default-features --features postgres --path plume-cli
|
RUN cargo install --no-default-features --features postgres --path plume-cli
|
||||||
|
RUN cargo clean
|
||||||
|
|
||||||
|
#-----------------------------
|
||||||
|
FROM debian:bullseye-slim
|
||||||
|
|
||||||
|
RUN apt-get update && apt-get install -y --no-install-recommends \
|
||||||
|
ca-certificates \
|
||||||
|
libpq5 \
|
||||||
|
libssl1.1
|
||||||
|
|
||||||
|
WORKDIR /app
|
||||||
|
|
||||||
|
COPY --from=builder /opt/plume /app
|
||||||
|
COPY --from=builder /usr/local/cargo/bin/diesel /usr/local/bin/
|
||||||
|
COPY --from=builder /usr/local/cargo/bin/plm /usr/local/bin/
|
||||||
|
COPY --from=builder /usr/local/cargo/bin/plume /usr/local/bin/
|
||||||
|
COPY plm-start /usr/local/bin/
|
||||||
|
|
||||||
|
CMD ["plm-start"]
|
||||||
|
|
||||||
|
EXPOSE 7878
|
||||||
|
|
3
app/build/plume/README.md
Normal file
3
app/build/plume/README.md
Normal file
|
@ -0,0 +1,3 @@
|
||||||
|
Try build:
|
||||||
|
|
||||||
|
sudo docker build -t superboum/plume:v1 --build-arg VERSION=003dcf861a9f55720b03d52f2f95f5f59e338809 .
|
5
app/build/plume/plm-start
Executable file
5
app/build/plume/plm-start
Executable file
|
@ -0,0 +1,5 @@
|
||||||
|
#!/bin/bash
|
||||||
|
|
||||||
|
diesel migration run
|
||||||
|
plm search init
|
||||||
|
plume
|
Loading…
Reference in a new issue