Hello, I’m hoping this is a very common use case but I haven’t quite been able to find the answer.
I have a dockerised rails app. I’d like to setup CI using GitHub Actions so that the docker image builds, the tests run within the image, and – assuming they pass – the image is pushed to docker hub.
I’ve had a workflow working for a while that builds and pushes the image. I suppose I could add a step to setup the database and another to run the tests, each using
By contrast, I spent a few hours today getting a rails test runner workflow working. I later realised it wouldn’t provide true parity since it doesn’t run in the docker container And right now if both jobs run, gems and node modules are fetched twice: once in the job runner and once in the docker build step within the job runner.
Surely there’s a common approach to this, right?