gitlab-runner exec limitations
Hello,
I need to setup gitlab-runner for one of our projects but ran into some issues. I want to use the docker method and this are my requirements:
- Before any testing can be done, the user needs to run a command to decrypt credentials stored in the repo, each "section" of the app has its own credentials which need to be decrypted on their own.
- There are "global" tests which should be just fine, but each "section" of the app has its own tests which need to be triggered on their own.
Requirement one is my biggest issue right now. Since gitlab-runner clones the repo into the container, I start from a blank slate and need to decrypt the files in the container. First problem is that I cannot get my private gpg key into the container because the environment
feature is not supported via the exec
command. Let's assume it is somehow possible, I am not sure how it would behave when the user needs to enter the key passphrase during decryption. It would be much easier if the decryption would be done on the host and the files would be copied into the container instead of a fresh clone.