Can I build an image, not publish it, and use it in child pipeline?

Can I build an image, not publish it, and use it in another child pipeline?


No. Child pipelines share nothing with the parent pipeline (apart for build parameters). The only way is to push the image to a registry.

This happens because a child pipeline can run in a different build node than the parent one (and in most cases it is a different node). So all the images built by the parent pipeline are not present on the execution context of the node that runs the child pipeline.

If you are worried about space/cost, there are many registry services with free tiers that you can use for temporary docker images.

I am trying to avoid YAML code duplication.
If CF had something like #include feature…

For small YAML snippets you might find useful YAML anchors useful Codefresh YAML · Codefresh | Docs

Regarding the include feature, we don’t have that right now. The approach we propose is to reuse the whole pipeline if possible Building Microservices · Codefresh | Docs