Photo by Dominik Lückmann on Unsplash

Compose Generator — Update 1.1.0

If you haven’t read about Compose Generator yet, visit the introduction article here. This particular article shows which features / improvements were added in version 1.1.0 of Compose Generator.

Service adding / generating rework

Originally, the generate sub-command only supported generating a stack from predefined service templates whereas the add command could only handle fully custom services. If you needed a mixture of both e.g. an own frontend service and an own backend service, combined with the predefined MySQL service, you formerly would have to generate the MySQL without frontend and backend with the generate command and subsequently add the other two services with the add command.

With v1.1.0 the generate command offers the menu option Custom service in each predefined service selection list at the bottom. If you select it, you get an “empty” service template like with the add command. In the same move we added support for predefined templates for the add command.

Extended list of predefined service templates

Service template tester

Compose Generator v1.1.0 introduces a new testing workflow for predefined service templates. Up to now, only the JSON and YAML files were validated in the sense of syntax, whereas now, every service template gets tested fully-automated on GitHub Actions. The workflow runs on every pull request which touches any predefined template.

Service tester workflow run

Logging and error handling mechanism

Up to v1.0.0 Compose Generator did not collect execution logs and printed the error messages + stack traces directy to the console. As this is not very consumer friendly, Compose Generator v1.1.0 introduces the maintainence of log files. These can be used to comprehend the execution path for reproducing bugs et al. The logfiles can be found at /usr/lib/compose-generator/log on Linux and ./log relative to the Compose Generator executable on Windows.

Part of a Compose Generator logfile

Further reading about Compose Generator

The key concept behind Compose Generator is, that it is durable and extensible. Therefore it is possible to create own predefined service templates and add them to the list of selectable services. If you do so, feel free to hand it in as a community contribution on GitHub!

There will be more upcoming articles regarding in-depth information about creating predefined service templates and all available cli subcommands!

Thank you for yourinterest and for reading this article.
If you want to learn more about Compose Generator, please visit the official documentation at www.compose-generator.com and the open source project on GitHub.

--

--

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store
Marc Auberer

Marc Auberer

C++ Compiler Developer at SAP. Passionate software developer and OpenSource enthusiast.