-
Notifications
You must be signed in to change notification settings - Fork 336
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
chore(docker-build): simplify the docker build process and reduce doc…
…ker image size (#9447) * Dockerfile basic created. Improvements added to reduce build time and size (down from 795MB to 445MB, depending on systemtap). Readme reduced, removing the old process used to build the image. * basic-env file using a RethinkDB database name that is clearly dedicated to the building proces. * Readme improved to run all three components * Unused dockerfiles removed. Docker entrypoint renamed. Docker Readme adapted * Legacy build kept in both dockerfile and env file. Readme adapted to use the new basic image. Build GH workflow adapted to use the new basic.dockerfile.
- Loading branch information
1 parent
052acd1
commit 5e356c2
Showing
10 changed files
with
69 additions
and
295 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
26 changes: 26 additions & 0 deletions
26
docker/parabol-ubi/docker-build/dockerfiles/basic.dockerfile
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,26 @@ | ||
ARG _NODE_VERSION=${_NODE_VERSION} | ||
FROM node:${_NODE_VERSION}-bookworm-slim as base | ||
|
||
ENV NPM_CONFIG_PREFIX=/home/node/.npm-global | ||
ENV PORT=3000 | ||
|
||
COPY --chown=node --chmod=755 docker/parabol-ubi/docker-build/entrypoints/docker-entrypoint.sh /usr/local/bin/docker-entrypoint.sh | ||
COPY --chown=node docker/parabol-ubi/docker-build/tools/ip-to-server_id ${HOME}/tools/ip-to-server_id | ||
|
||
# Required for pushToCDN to work with FILE_STORE_PROVIDER set to 'local' | ||
RUN mkdir -p ${HOME}/parabol/self-hosted && \ | ||
chown node:node ${HOME}/parabol/self-hosted | ||
|
||
COPY --chown=node .env.example ${HOME}/parabol/.env.example | ||
|
||
# The application requires a yarn.lock file on the root folder to identify it | ||
COPY --chown=node yarn.lock ${HOME}/parabol/yarn.lock | ||
COPY --chown=node build ${HOME}/parabol/build | ||
COPY --chown=node dist ${HOME}/parabol/dist | ||
|
||
WORKDIR ${HOME}/parabol/ | ||
|
||
USER node | ||
EXPOSE ${PORT} | ||
|
||
ENTRYPOINT ["docker-entrypoint.sh"] |
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
117 changes: 0 additions & 117 deletions
117
docker/parabol-ubi/docker-build/dockerfiles/pipeline.dockerfile
This file was deleted.
Oops, something went wrong.
Oops, something went wrong.