Replies: 3 comments 5 replies
-
I agree, that would be nice. run: molecule -e env-centos-7 test in env-centos-7:
in molecule.yml: platforms:
- name: ${CI_HOSTNAME:-ci-centos8}
image: ${CI_IMAGE:-quay.io/centos/centos:8}
... |
Beta Was this translation helpful? Give feedback.
1 reply
-
you make an env file for each of them and you define a variable like matrix.platform (you called it matrix.package above, was this a typo?).
|
Beta Was this translation helpful? Give feedback.
3 replies
-
It would be better to filter data in https://github.com/ansible-community/molecule/blob/main/src/molecule/provisioner/ansible.py#L607
Before:
AFTER
|
Beta Was this translation helpful? Give feedback.
1 reply
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Support
--platform
formolecule test
command.e.g.
Only test role on
centos-7
platform indefault
scenario, if no platform found, raise error.Q: Why is this required?
A: Assume there are 10 platform docker images defined in
molecule.yml
and only one image(centos-7) are changed.--platform
, only one changed docker image would be tested viamolecule test --platform centos-7
--platform
, all 10 platform docker image would be test while the other 9 are redundant.More specifically, the
run: molecule test
can ben changed torun: molecule test --platform ${{ matrix.package }}
.https://github.com/zhan9san/systemd/blob/main/.github/workflows/ci.yml#L70
Beta Was this translation helpful? Give feedback.
All reactions