'GitHub Actions: How can I cache the Docker images for Testcontainers?

I execute some tests in GitHub Actions using Testcontainers.

Testcontainers pulls the images which are used in my tests. Unfortunately the images are pulled again at every build.

How can I cache the images in GitHub Actions?



Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source