parent
700154e311
commit
ee514ecb20
6 changed files with 31 additions and 13 deletions
@ -1,4 +1,4 @@ |
|||||||
FROM rust:1.53 |
FROM rust:1.55 |
||||||
|
|
||||||
RUN rustup target add x86_64-unknown-linux-musl |
RUN rustup target add x86_64-unknown-linux-musl |
||||||
CMD ["sleep", "3600"] |
CMD ["sleep", "3600"] |
@ -1,3 +1,11 @@ |
|||||||
FROM postgres:13.3 |
FROM postgres:13.3 |
||||||
|
|
||||||
RUN apt update && apt -y upgrade && apt install -y iproute2 |
RUN apt update && apt upgrade -y |
||||||
|
RUN apt install -y curl build-essential libpq-dev iproute2 |
||||||
|
RUN curl https://sh.rustup.rs -sSf | sh -s -- -y --default-toolchain stable --profile minimal |
||||||
|
ENV PATH /root/.cargo/bin:$PATH |
||||||
|
RUN rustup target add x86_64-unknown-linux-musl |
||||||
|
RUN cargo install diesel_cli --no-default-features --features postgres |
||||||
|
|
||||||
|
RUN mkdir -p /unki |
||||||
|
COPY u_db_entrypoint.sh /unki/ |
@ -0,0 +1,5 @@ |
|||||||
|
set -m |
||||||
|
|
||||||
|
export DATABASE_URL=postgres://${DB_USER}:${DB_PASSWORD}@127.0.0.1/${DB_NAME} |
||||||
|
/usr/local/bin/docker-entrypoint.sh postgres & |
||||||
|
sleep 10 && diesel setup && fg %1 |
@ -1,3 +1,3 @@ |
|||||||
FROM rust:1.53 |
FROM alpine:latest |
||||||
|
|
||||||
RUN cargo install diesel_cli --no-default-features --features postgres |
RUN apk add iproute2 bash |
Loading…
Reference in new issue