mirror of
https://github.com/dani-garcia/bitwarden_rs
synced 2024-11-22 09:55:57 +01:00
Updated dockerfiles to use compiled vaults
This commit is contained in:
parent
a1272c7190
commit
7ebba736cb
16
Dockerfile
16
Dockerfile
@ -2,27 +2,21 @@
|
|||||||
# https://docs.docker.com/develop/develop-images/multistage-build/
|
# https://docs.docker.com/develop/develop-images/multistage-build/
|
||||||
# https://whitfin.io/speeding-up-rust-docker-builds/
|
# https://whitfin.io/speeding-up-rust-docker-builds/
|
||||||
####################### VAULT BUILD IMAGE #######################
|
####################### VAULT BUILD IMAGE #######################
|
||||||
FROM node:10-alpine as vault
|
FROM alpine as vault
|
||||||
|
|
||||||
ENV VAULT_VERSION "v2.6.1"
|
ENV VAULT_VERSION "v2.6.1"
|
||||||
|
|
||||||
ENV URL "https://github.com/bitwarden/web.git"
|
ENV URL "https://github.com/dani-garcia/bw_web_builds/releases/download/$VAULT_VERSION/bw_web_$VAULT_VERSION.tar.gz"
|
||||||
|
|
||||||
RUN apk add --update-cache --upgrade \
|
RUN apk add --update-cache --upgrade \
|
||||||
curl \
|
curl \
|
||||||
git \
|
|
||||||
tar
|
tar
|
||||||
|
|
||||||
RUN git clone -b $VAULT_VERSION --depth 1 $URL web-build
|
RUN mkdir /web-build
|
||||||
WORKDIR /web-build
|
WORKDIR /web-build
|
||||||
|
|
||||||
COPY /docker/set-vault-baseurl.patch /web-build/
|
RUN curl -L $URL | tar xz
|
||||||
RUN git apply set-vault-baseurl.patch
|
RUN ls
|
||||||
|
|
||||||
RUN npm run sub:init && npm install
|
|
||||||
|
|
||||||
RUN npm run dist \
|
|
||||||
&& mv build /web-vault
|
|
||||||
|
|
||||||
########################## BUILD IMAGE ##########################
|
########################## BUILD IMAGE ##########################
|
||||||
# We need to use the Rust build image, because
|
# We need to use the Rust build image, because
|
||||||
|
@ -2,27 +2,21 @@
|
|||||||
# https://docs.docker.com/develop/develop-images/multistage-build/
|
# https://docs.docker.com/develop/develop-images/multistage-build/
|
||||||
# https://whitfin.io/speeding-up-rust-docker-builds/
|
# https://whitfin.io/speeding-up-rust-docker-builds/
|
||||||
####################### VAULT BUILD IMAGE #######################
|
####################### VAULT BUILD IMAGE #######################
|
||||||
FROM node:10-alpine as vault
|
FROM alpine as vault
|
||||||
|
|
||||||
ENV VAULT_VERSION "v2.6.1"
|
ENV VAULT_VERSION "v2.6.1"
|
||||||
|
|
||||||
ENV URL "https://github.com/bitwarden/web.git"
|
ENV URL "https://github.com/dani-garcia/bw_web_builds/releases/download/$VAULT_VERSION/bw_web_$VAULT_VERSION.tar.gz"
|
||||||
|
|
||||||
RUN apk add --update-cache --upgrade \
|
RUN apk add --update-cache --upgrade \
|
||||||
curl \
|
curl \
|
||||||
git \
|
|
||||||
tar
|
tar
|
||||||
|
|
||||||
RUN git clone -b $VAULT_VERSION --depth 1 $URL web-build
|
RUN mkdir /web-build
|
||||||
WORKDIR /web-build
|
WORKDIR /web-build
|
||||||
|
|
||||||
COPY /docker/set-vault-baseurl.patch /web-build/
|
RUN curl -L $URL | tar xz
|
||||||
RUN git apply set-vault-baseurl.patch
|
RUN ls
|
||||||
|
|
||||||
RUN npm run sub:init && npm install
|
|
||||||
|
|
||||||
RUN npm run dist \
|
|
||||||
&& mv build /web-vault
|
|
||||||
|
|
||||||
########################## BUILD IMAGE ##########################
|
########################## BUILD IMAGE ##########################
|
||||||
# We need to use the Rust build image, because
|
# We need to use the Rust build image, because
|
||||||
|
@ -2,27 +2,21 @@
|
|||||||
# https://docs.docker.com/develop/develop-images/multistage-build/
|
# https://docs.docker.com/develop/develop-images/multistage-build/
|
||||||
# https://whitfin.io/speeding-up-rust-docker-builds/
|
# https://whitfin.io/speeding-up-rust-docker-builds/
|
||||||
####################### VAULT BUILD IMAGE #######################
|
####################### VAULT BUILD IMAGE #######################
|
||||||
FROM node:10-alpine as vault
|
FROM alpine as vault
|
||||||
|
|
||||||
ENV VAULT_VERSION "v2.6.1"
|
ENV VAULT_VERSION "v2.6.1"
|
||||||
|
|
||||||
ENV URL "https://github.com/bitwarden/web.git"
|
ENV URL "https://github.com/dani-garcia/bw_web_builds/releases/download/$VAULT_VERSION/bw_web_$VAULT_VERSION.tar.gz"
|
||||||
|
|
||||||
RUN apk add --update-cache --upgrade \
|
RUN apk add --update-cache --upgrade \
|
||||||
curl \
|
curl \
|
||||||
git \
|
|
||||||
tar
|
tar
|
||||||
|
|
||||||
RUN git clone -b $VAULT_VERSION --depth 1 $URL web-build
|
RUN mkdir /web-build
|
||||||
WORKDIR /web-build
|
WORKDIR /web-build
|
||||||
|
|
||||||
COPY /docker/set-vault-baseurl.patch /web-build/
|
RUN curl -L $URL | tar xz
|
||||||
RUN git apply set-vault-baseurl.patch
|
RUN ls
|
||||||
|
|
||||||
RUN npm run sub:init && npm install
|
|
||||||
|
|
||||||
RUN npm run dist \
|
|
||||||
&& mv build /web-vault
|
|
||||||
|
|
||||||
########################## BUILD IMAGE ##########################
|
########################## BUILD IMAGE ##########################
|
||||||
# Musl build image for statically compiled binary
|
# Musl build image for statically compiled binary
|
||||||
|
@ -2,27 +2,21 @@
|
|||||||
# https://docs.docker.com/develop/develop-images/multistage-build/
|
# https://docs.docker.com/develop/develop-images/multistage-build/
|
||||||
# https://whitfin.io/speeding-up-rust-docker-builds/
|
# https://whitfin.io/speeding-up-rust-docker-builds/
|
||||||
####################### VAULT BUILD IMAGE #######################
|
####################### VAULT BUILD IMAGE #######################
|
||||||
FROM node:10-alpine as vault
|
FROM alpine as vault
|
||||||
|
|
||||||
ENV VAULT_VERSION "v2.6.1"
|
ENV VAULT_VERSION "v2.6.1"
|
||||||
|
|
||||||
ENV URL "https://github.com/bitwarden/web.git"
|
ENV URL "https://github.com/dani-garcia/bw_web_builds/releases/download/$VAULT_VERSION/bw_web_$VAULT_VERSION.tar.gz"
|
||||||
|
|
||||||
RUN apk add --update-cache --upgrade \
|
RUN apk add --update-cache --upgrade \
|
||||||
curl \
|
curl \
|
||||||
git \
|
|
||||||
tar
|
tar
|
||||||
|
|
||||||
RUN git clone -b $VAULT_VERSION --depth 1 $URL web-build
|
RUN mkdir /web-build
|
||||||
WORKDIR /web-build
|
WORKDIR /web-build
|
||||||
|
|
||||||
COPY /docker/set-vault-baseurl.patch /web-build/
|
RUN curl -L $URL | tar xz
|
||||||
RUN git apply set-vault-baseurl.patch
|
RUN ls
|
||||||
|
|
||||||
RUN npm run sub:init && npm install
|
|
||||||
|
|
||||||
RUN npm run dist \
|
|
||||||
&& mv build /web-vault
|
|
||||||
|
|
||||||
########################## BUILD IMAGE ##########################
|
########################## BUILD IMAGE ##########################
|
||||||
# We need to use the Rust build image, because
|
# We need to use the Rust build image, because
|
||||||
|
Loading…
Reference in New Issue
Block a user