mirror of
https://github.com/EvolutionAPI/evolution-api.git
synced 2025-07-16 04:02:54 -06:00
chore: Dockerfile
This commit is contained in:
parent
6d6f7293f9
commit
99ebb81838
18
Dockerfile
18
Dockerfile
@ -1,10 +1,7 @@
|
|||||||
FROM node:20-bullseye-slim AS base
|
FROM node:20-alpine AS builder
|
||||||
|
|
||||||
RUN apt-get update -y && apt-get upgrade -y && \
|
RUN apk update && \
|
||||||
apt-get install -y git tzdata ffmpeg wget curl && \
|
apk add git ffmpeg wget curl bash
|
||||||
npm i -g npm@latest
|
|
||||||
|
|
||||||
FROM base AS builder
|
|
||||||
|
|
||||||
LABEL version="2.0.0" description="Api to control whatsapp features through http requests."
|
LABEL version="2.0.0" description="Api to control whatsapp features through http requests."
|
||||||
LABEL maintainer="Davidson Gomes" git="https://github.com/DavidsonGomes"
|
LABEL maintainer="Davidson Gomes" git="https://github.com/DavidsonGomes"
|
||||||
@ -24,13 +21,16 @@ COPY ./.env.example ./.env
|
|||||||
|
|
||||||
COPY ./Docker ./Docker
|
COPY ./Docker ./Docker
|
||||||
|
|
||||||
RUN chmod +x ./Docker/scripts/*
|
RUN chmod +x ./Docker/scripts/* && dos2unix ./Docker/scripts/*
|
||||||
|
|
||||||
RUN ./Docker/scripts/generate_database.sh
|
RUN ./Docker/scripts/generate_database.sh
|
||||||
|
|
||||||
RUN npm run build
|
RUN npm run build
|
||||||
|
|
||||||
FROM base AS final
|
FROM node:20-alpine AS final
|
||||||
|
|
||||||
|
RUN apk update && \
|
||||||
|
apk add tzdata ffmpeg
|
||||||
|
|
||||||
ENV TZ=America/Sao_Paulo
|
ENV TZ=America/Sao_Paulo
|
||||||
|
|
||||||
@ -50,4 +50,4 @@ COPY --from=builder /evolution/Docker ./Docker
|
|||||||
|
|
||||||
ENV DOCKER_ENV=true
|
ENV DOCKER_ENV=true
|
||||||
|
|
||||||
ENTRYPOINT ["/bin/bash", "-c", ". ./Docker/scripts/deploy_database.sh && npm run start:prod" ]
|
ENTRYPOINT ["/bin/bash", "-c", ". ./Docker/scripts/deploy_database.sh && npm run start:prod" ]
|
Loading…
Reference in New Issue
Block a user