42 points · by jayjohnson · 10y ago · 25 comments
OP why are these needed? Can you remove them?
Database provisioning: why not implement a generic createdb(1M) program with required command line switches which OS packages delivering the required filesystem structures could call in their postinstall phase? I wrote such a program (for Oracle DB) in shell and AWK and it works great for all sorts of OS configuration packages which create all kinds of databases; it makes Docker completely unnecessary, not to mention superflouous;
Substrate choice: what techical advantages does Docker provide over imgadm(1M) and zones built into SmartOS ("people might be more familiar with Linux and Docker" is not a technical advantage)?
Back to your points, can I ask if you are interested in using this container approach to build a database container cluster in docker and then benchmark against a working imgadm(1M) + SmartOS environment? From the docker-side when I scale out a cluster of database runtime-only containers, I utilize the volume mounting attribute that is commented out in the repo's compose file (https://github.com/jay-johnson/docker-schema-prototyping-wit...) and then host the database files outside of the containers in a persistent storage location that is mounted + available on the hosts where the docker containers are running. As for building the database container for this proposed solution I would still utilize this Docker Compose-centric approach in development and then in production because I can build the container one time and not deal with a rebuild which invalidates testing a container within my DevOps artifact pipeline.
Wrapping up, I live more on the application development side so I cannot speak specifically to SmartOS or imgadm(1M), but I know the docker documentation and community are pretty helpful for getting/finding technical solutions that helped me build + launch products (go team!). If you are interested we can discuss more details about how I would approach bench marking these two database environments. I am a big proponent of testing everything and I would enjoy discussing how to tackle a db perf/load/ha + test harness like my message simulator (https://github.com/GetLevvel/message-simulator).
Feel free to connect with me on LinkedIn anytime: https://www.linkedin.com/in/jay-johnson-27a68b8a
vmadm(1M) provisioning can take anywhere from 5 to 25 seconds.
Oracle DB provisioning with my program takes 45 minutes, as it performs a CREATE DATABASE and is constant irrespective of hardware.
this seems like it has fewer moving parts.
# docker run -itd --name=AppDeployedToNode1 --env="constraint:node==swarm1.internallevvel.com" busybox
# docker run -itd --name=AppDeployedToNode2 --env="constraint:node==swarm2.internallevvel.com" busybox
# docker run -itd --name=AppDeployedToNode3 --env="constraint:node==swarm3.internallevvel.com" busybox
RabbitMQ Example - https://gist.github.com/jay-johnson/2673ce4df42317667908#fil...
Looking back I feel like it was a lot of effort to deploy 3 busybox instances or that initial RabbitMQ cluster…and that effort to handle the “production deployment case” as early as possible is what set me on the path to the new Docker Compose-centric approach discussed in the link above.
I had tried Compose in a previous incarnation of Matsuri, but Compose has flaws in it that Kubernetes solves.
Besides, that code doesn't make sense without an example. The best example is locked behind proprietary code. Feel free to ping me if you want me to walk you through what it is about.
It is not about time. We have 24 hours every day, everyone has lots of things to do.
If I could read just one or two sentences describing what your code does, I had at least some basic information to consider if it is worth spending some time on this.
As there is nothing and you think it is a waste of time to document that code, why should I spend my time with some code that you think is a waste of time to document?
Anyway, have a nice day!
In other words, a Dockerfile specifies what you want to build, and a compose file specifies how you will run it.