Hi all,
Following the great conversations in the threads below — which represent a significant step forward in achieving more consistent and modern software development and deployment practices — I’d like to propose an additional improvement to help fully realize the underlying goals:
Why The above Efforts Matter
Both development and deployment workflows fundamentally require a correctly provisioned environment — typically involving compatible versions of Java, Maven, and system-level dependencies. Docker allows this environment to be defined and shared consistently, avoiding “it works on my machine” problems and making CI/CD pipelines more predictable at the same time improving developer experience.
The benefits can be summarised as, being able to:
- Provide a standardized, reproducible runtime across teams and platforms.
- Eliminate local/host system dependency issues.
- Improve developer onboarding by reducing setup complexity.
- Make it easier to test against OpenMRS distributions or module versions.
It is from the last point above that I’d like to discuss an area to improve on the OpenMRS SDK. The OpenMRS SDK already provides powerful features for managing development servers, creating distributions, and scaffolding modules.
During module development, being able to also build deployable module based distributions can be great addition to the above efforts. Here is where this would lead to — being able to generate a run-able distribution based on a module’s config.xml
file which consequently involves resolving the transitively required modules. With this, we would eliminate the need to have extra distro-properties.xml
or docker-compopse.yml
files residing within modules.
Proposed Enhancements to the OpenMRS SDK
-
Introduce a lightweight function to build a distribution based on a module’s
config.xml
file, into the OpenMRS SDK. -
Extend existing OpenMRS SDK commands to Support 1 above, such as:
mvn openmrs-sdk:build-distro -Dmodule-based # Build module based Dockerized distribution
The command can be run locally or executed within a mounted Docker container. This improvement is optional and opt-in for devs and, as usual, allows for execution in CI environments
Devs are allowed to define or override Docker Compose instance files as part of their project deployment setups, enabling custom local dev stacks.
Looking forward to your thoughts and feedback @ibacher, @dkayiwa, @wikumc, @raff, @mseaton, @dev5, @dev4, @dev3, and anyone else interested in improving our tooling