This repository has been archived by the owner on Jan 5, 2023. It is now read-only.
Best Practices for Monolith Repo and Container Image use with Molecule #134
Unanswered
DanSibbernsen
asked this question in
Q&A
Replies: 0 comments
# for free
to join this conversation on GitHub.
Already have an account?
# to comment
-
Hi! Been using Molecule for a few weeks now, and I'm slowly getting the hang of it. My use case is a monolith repo with many roles that I'm deploying to SUSE. I have a container image that now works for my purposes, but I also have cluttered my roles with repeated Molecule files (molecule.yml, Dockerfile.j2, prepare.yml, cleanup.yml) that are 100% copy / paste across all my roles
I started digging into the
.config/molecule/config.yml
and realized I could transplant almost all of my repeated yml files into a.config
directory and usemolecule --base-config
, so then I ended up with these directory structuresEverything except the
Dockerfile.j2
seemed to work fine. Digging into PR51 and the 1.0.1 Discussion, I figured the changes that would make transplanting thedockerfile
into another directory were probably counter-intuitive to this module, hence why those changes were removed.So now I'm wondering: for a monolith repo that uses the same container image over and over again, is it best to just create a container image beforehand and have molecule use that? As opposed to having molecule create the image?
Any feedback on my approach is much appreciated.
Beta Was this translation helpful? Give feedback.
All reactions