-
Notifications
You must be signed in to change notification settings - Fork 10.9k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Update Dockerfile to not depend on custom base image #17802
Conversation
Awesome. Also improves transparency of implementation for open source community. (Even though source to base is available, it requires effort to locate and is mostly mysterious.) |
I don’t see any of the removed items as a breaking change so long as functionality of rc doesn’t some how depend on them. The only downside I guess really is the one liner to prep stuff is kinda long. Wonder if putting in a single script that is added early on and cached would be acceptable? |
Can we put all prep of the image in one layer, and then add /app and finally the npm install and cleanup? That way we maximize cache? |
you mean move other things to same layer as the nodejs installation? I've done this way to keep it easy to update, so one layer for node and another one for rocket.chat stuff (user creation and dependencies). although maximising cache is good, we don't have docker cache on github actions 😞 |
This is technically valid and we could probably merge. Just doesn’t feel like a great dockerfile. But I might be spoiled to dockerizing go binaries ;) A thought/question? Do we want to keep maintaining nodejs inside? If I remember right originally we started off with the rocketchat/base image not because of nodejs. But actually because we wanted to pack our gpg keys and nodejs both in so when we fetched from the release service we could verify. but since we are bringing the bundle in from the ci. That original purpose is gone. On the official image we deviated from a nodejs because it vanished on us. Do we have that worry here or could we depend on it? For the mongo all in one I think we have no choice. But for our main image? |
right, I guess we can be based on official I'll make the changes and update the PR description.. =) |
There we go! That doesn’t feel so massive |
…apps_rewrite* 'develop' of github.com:RocketChat/Rocket.Chat: (28 commits) [IMPROVE] Performance editing Admin settings (#17916) [IMPROVE] React hooks lint rules (#17941) [FIX] StreamCast stream to server only streamers (#17942) [FIX] Profile save button not activates properly when changing the username field (#16541) [FIX] Outgoing webhook: Excessive spacing between trigger words (#17830) [FIX] Links being escaped twice leading to visible encoded characters (#16481) [NEW][API] New endpoints to manage User Custom Status `custom-user-status.create`, custom-user-status.delete` and `custom-user-status.update` (#16550) [FIX] Message action popup doesn't adjust itself on screen resize (#16508) [FIX] Not possible to translate the label of custom fields in user's Info (#15595) [FIX] Close the user info context panel does not navigate back to the user's list (#14085) [FIX] Missing pinned icon indicator for messages pinned (#16448) Chatpal: limit results to current room (#17718) Do not build Docker image for fork PRs (#17370) [IMPROVE] Use REST for DDP calls by default (#17934) [IMPROVE] Add rate limiter to UiKit endpoints (#17859) LingoHub based on develop (#17796) [IMPROVE] Change default upload settings to only block SVG files (#17933) Update Dockerfile to not depend on custom base image (#17802) [IMPROVE][Performance] Add new database indexes to improve data query performance (#17839) [FIX] Undesirable message updates after user saving profile (#17930) ...
Proposed changes
Depending on "base image" adds an additional step every time we need to update a dependency on our Docker image so I'm changing the base image to a
node-slim
.I have also updated to Debian Buster (previously using Stretch), the current stable version.
Some changes described below might be considered breaking, so please let me know if I need to change anything.
Issue(s)
RocketChat/Docker.Official.Image#112 (comment)
How to test or reproduce
Screenshots
Types of changes
Checklist
Changelog
Further comments
Some important changes included in this change:
imagemagick
dependency - it was used before to resize uploaded images, but we're currently usingsharp
that doesn't depend onimagemagick