forked from muety/mailwhale
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
2 changed files
with
33 additions
and
10 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
# Build Stage | ||
|
||
FROM golang:1.19 AS api-build-env | ||
|
||
WORKDIR /app | ||
|
||
FROM node:18 AS ui-build-env | ||
|
||
WORKDIR /src | ||
ADD webui . | ||
RUN yarn && \ | ||
yarn build | ||
|
||
# Run Stage | ||
|
||
# When running the application using `docker run`, you can pass environment variables | ||
# to override config values using `-e` syntax. | ||
|
||
FROM alpine | ||
WORKDIR /app | ||
|
||
COPY mailwhale README.md version.txt LICENSE config.yml templates/ ./ | ||
COPY --from=ui-build-env /src/public ./webui/public | ||
|
||
ENV MW_ENV=prod | ||
ENV MW_WEB_LISTEN_V4=0.0.0.0:3000 | ||
ENV MW_STORE_PATH=/data/data.json.db | ||
|
||
VOLUME /data | ||
|
||
ENTRYPOINT ./mailwhale |