-
Notifications
You must be signed in to change notification settings - Fork 2.4k
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
[ADD] Zabbix components Official docker images #6065
base: master
Are you sure you want to change the base?
Conversation
Merge with Official
This looks like it's a lot of very similar inter-related images -- is that the case? They all appear to share roughly the same structure with the same version numbers, so they appear to all be part of the larger "Zabbix" release as a whole. Is that accurate? What I'd like to see here is a restructuring of the tags to fit the conventions of existing official images -- I don't think this warrants 11 separate image repositories for what all amount to essentially components of the greater Zabbix experience (especially with how much that's going to fragment the documentation for each, which I'm guessing aren't designed to be used standalone?). Here are some ideas for tagging structures that match some other official images:
Then things like
or
This helps make it clear that the "4.2.3" portion of that is the general Zabbix release version and that the other portions are the specific component of that Zabbix release that we're interested in. I'm also curious about the rationale for having both Ubuntu and CentOS-based images -- what's the use case for maintaining both of those? I get the argument for having one or the other of them, but no matter which one you choose it should run fine on either host OS, and then having Alpine alongside that is useful in order to achieve a smaller footprint (assuming Zabbix is officially supported on the Alpine platform / musl libc), but I'm having a hard time understanding the use case for supporting both Ubuntu and CentOS variants. Isn't one or the other of those more highly recommended by Zabbix upstream? (and thus a better candidate for focusing on?) Additionally, many of the Also, a surprising number of the commits over on https://github.com/zabbix/zabbix-docker appear to be made by |
Agree, probably it is a good idea to merge different database images. But I'm not sure how merge all into one, because in this case documentation will become huge! It is possible to use components standalone, but usually they are not used as standalone solution. Server and frontend components are mandatory, all others are optional and required for different purposes (like extended monitoring or monitoring remote locations behind NAT).
Actually because of 3rd party library issues :-) But I agree with you it is better to support only one OS. Which one is better (Ubuntu or CentOS) according Docker guidelines?
We made it exactly for more clear Dockerfiles and to avoid garbage in final images. If it is not supported officially we can review images and avoid multistage where it is possible. Is It better to avoid it?
Sorry for that. Will do it! Thank you! |
Hello tianon! Sorry for bothering you! Did you check my comments? |
Indeed -- those should definitely be under the same namespace. Given the assumption that the documentation for each of the five components is going to be very different, I think having five images is likely reasonable.
If you've got a lot of third-party library issues, I'd recommend choosing the one with the least number of those, but if that's not an easy choice, the best I can offer between those two is that Ubuntu is updated a lot more regularly (and is generally smaller).
We definitely recommend avoiding it if it isn't actually necessary -- for RPM-based images, it's a bit complicated to clean up properly, but for APT/deb-based and Alpine-based images it's really not very difficult, and I'd be happy to help with any conversions there. |
Thank you for your help! So finally we think Alpine-based images are the best option! Sorry, probably I did not quite understand you about the same namespace and different images. But what do you think about the following structure:
Is it correct idea? I'm not sure that "zabbix-appliance" is needed at all. What do you think? Also I removed multistage on Alpine images at all. Now I think they are better :-) I have another question, we have our own repository zabbix/. How it must be usually with non-official repositories? Can we keep it or remove? Is there any restrictions? |
Hello! Could you check my previous comment? |
Yeah, those look more reasonable, although still a bit of a broad set of images and I'm not thrilled that they're not really "generally useful" split apart separately (see #6282 for our Also to be clear, there's no requirement to specify
That does seem unnecessary and unlikely to be acceptable here -- it bundles everything right? It seems better to document appropriately how to run all the components appropriately connected together.
Totally up to you -- you're free to keep it and continue using it, or you can remove it. Some upstreams like to build/push the same things in both places, some like to ditch the org once they have an image, some prefer to use their organization namespace to push experimental or bleeding edge builds, etc. |
Hi! Guys, we have no answer for 20 days about status of our current submission. Please provide either some comments or next steps we have to take to move forward on this subject. Thank you in advance! |
Sorry, I think we're still disconnected on the "generally useful" bit -- each of these images is not individually "generally useful" and on top of that we don't have any real prior precedent for such a large single-software sprawl of separate images. I think the ELK or TICK stacks are the closest analogs we have, but in those cases they're still individually useful. Elasticsearch is a generic time-series database. Logstash is a generic log-stream processor (Elasticsearch is simply one optional input/output plugin among many others within it). Stealing from
Each of these really seems like a tightly coupled or optional component of a standard Zabbix installation. What makes Agent and Java Gateway different? What makes Proxy separate from those? Regarding documentation, we very frequently recommend that maintainers document the minimum and refer folks to external documentation for more detailed usage information -- see https://hub.docker.com/_/registry for a good example of doing that very minimally ("here's a basic It might also help to start with the core subset of Zabbix functionality -- for example, is it strictly necessary for Java Gateway and the Proxy bits to be part of the initial Zabbix official image, or are they optional extra components which could just as easily be added after-the-fact? (or even a 3rd party replacement?) Are these similar to Prometheus's "exporters"? From what I can see, the core set would be Agent, Server, and Web, and the MVP high-level usage would be as simple as |
Thank you for your reply. We now with all explanation agree to your suggested model. Starting to reconfigure everything. Hope to provide another image in just few days |
Will the images themselves remain roughly the same? (In other words, could
we start the meat of the Dockerization review in the meantime?)
|
Hello! Yes, images will be the same, I will just change repositories into 1 with different tags for Zabbix components. |
Perfect, we should be able to multiplex a little here then. I took a brief look over the Dockerization, and I'm a bit confused by the ~1000 line shell script -- I get the intent (especially given the removed "appliance" image), but for something like "run the agent" it appears to amount to essentially "copy a few environment variables into the config and fire off What we'd typically recommend for this sort of scenario instead is to have a simple script that just sets up the configuration followed by As-written, it also might give users the impression that they can simply modify a few environment variables and expect the image to do something drastically different, but looking at the compilation flags on Zabbix (and the copied binaries), that's not really the case. There's also reference to In the It seems strange to be setting Image label names should adhere to https://github.com/opencontainers/image-spec/blob/v1.0.1/annotations.md (chiefly Those I noticed the agent appears to have a volume defined on Using |
Yes, Zabbix agent and others components have additional arguments as well (for example, test metrics, increase/decrease debugging). Actually I use the same shell script for all images, just to have consistent.
Supervisord is used in web Nginx based images. We need php-fpm + nginx there.
These variables are specified to be unified with all images. Some of them require, some not. So you prefer to remove empty ones?
Yes. Zabbix can process SIG_USER. So we need to be sure that only TERM is used to stop containers.
Sorry, did not understand, which one is better to use now?
Will do! Thank you! But anyway I checked all images orphaned files and I did not find them :-)
Yes, users can extend configuration using additional files. Like virtual hosts in Nginx or Apache.
I know that issue, but in case of Zabbix no issues at all. I checked it already many times :-)
|
Hello Tianon! Sorry for bothering you! Did you check my comment? |
Right, I get the intention, but the end result is that it's a very long shell script, and that most of it doesn't apply to any given image that it's included in, and it's a bit hard to follow and understand what it's doing as a result.
Running
I just don't understand their purpose -- most of them are only used once or twice, and I think it would be more straightforward to just embed their values in the places they are used?
Sorry, I wasn't referring to
All labels should be using reverse-DNS notation (
So in that case, I'd recommend ditching the |
|
|
FROM zabbix:X.Y.Z-foo
RUN ... > /etc/zabbix/...
# or
COPY ... /etc/zabbix/.../ If the |
Hello Tianon! I have changed images according your requirements. Currently I merged only 3.0 branch (https://github.com/zabbix/zabbix-docker/tree/3.0). Could you check it and approve if everything is good? |
Hi, Tianon! May I kindly ask you to a provide your feed-back on recently submitted images? Thank you in advance! |
Hi, guys! |
Looking at just https://github.com/zabbix/zabbix-docker/tree/3.0/agent/alpine for now to simplify review (because this is frankly a lot, and I think many of the others are similar): ARG APK_FLAGS_PERSISTENT="--clean-protected --no-cache"
ARG APK_FLAGS_DEV="--no-cache" Hadn't we discussed removing these variables? ENV TERM=xterm ZBX_VERSION=${ZBX_VERSION} ZBX_SOURCES=${ZBX_SOURCES} Is Also, all the version-number-embedding lines should be moved as far down in the apk update && \ Given that you're using alpine-sdk \ This package is specifically for building Alpine packages (which this isn't doing), so I'd recommend switching to a smaller set of packages to install based on which of that package's dependencies are actually required instead ( set -eo pipefail
set +e This seems kind of odd -- why ZBX_SERVER_HOST=${ZBX_SERVER_HOST:-"zabbix-server"} You'll likely be interested in https://www.gnu.org/savannah-checkouts/gnu/bash/manual/bash.html#Shell-Parameter-Expansion, especially : ${ZBX_SERVER_HOST:="zabbix-server"} exec su zabbix -s "/bin/bash" -c "/usr/sbin/zabbix_agentd --foreground -c /etc/zabbix/zabbix_agentd.conf" Does
(from the I don't think the existing entrypoint is going to pass the tests as-is. |
Hello! Thank you! Probably I fixed everything you mentioned. Could you check for any other issues in https://github.com/zabbix/zabbix-docker/tree/3.0/ ? And yes, not it passed test checks :-) Kind regards, |
Hello! Sorry for bothering you! Is there any news? |
Any news? ;-) |
Hello! Sorry for bothering you. Did you check my previous comments? |
Diff for 6141ef2:failed fetching repo "zabbix"
unable to find a manifest named "zabbix" (in "/tmp/tmp.bTvop6GFoR/oi/library" or as a remote URL)
cp: cannot stat 'tar/zabbix_3.0-agent/["docker-entrypoint.sh",': No such file or directory |
Added Zabbix components for Official docker images.
These images are related to Zabbix monitoring system components.
Also, please, check documentation pull request.
Checklist for Review
NOTE: This checklist is intended for the use of the Official Images maintainers both to track the status of your PR and to help inform you and others of where we're at. As such, please leave the "checking" of items to the repository maintainers. If there is a point below for which you would like to provide additional information or note completion, please do so by commenting on the PR. Thanks! (and thanks for staying patient with us ❤️)
foobar
needs Node.js, hasFROM node:...
instead of grabbingnode
via other means been considered?)FROM scratch
, tarballs only exist in a single commit within the associated history?