How to pull multiple docker images in single gitlab file

I want pull docker images from my nexus repo and push it to another nexus repo.

My issue is in that repo we have more than 300 images so i want to pull it in single .gitlab file so how to mention that images in .gitlab

Or.
Any other method is available ?

And what kind of executer do i need to use?

A docker repository isn’t going to pull all images in one file. Docker pulls images individually by default, so this link will give you info on how to pull multiple images: docker pull | Docker Documentation

To push images downloaded to the new location, you have to usually use the source and destination, so you will have to script that by using some kind of loop based on source and destination. Or tag them and then push all of them based on the tags. See: docker push | Docker Documentation

If I understood correctly, you want to push existing images from one registry to another using GitLab CI?

In that case, you should create a script that would loop over those 300 images and:

  • download image (docker pull <image-name>)
  • re-tag image (as image names are in format of <registry-name>/<path-to-the-image>/<image-name>:<tag>) with the registry name of the second nexus server (like mentioned by @iwalker )
  • push that image

Then you can clean up all downloaded images with sth like docker image prune --all

I’d suggest using either docker executor with dind service running with your job, or directly a shell executor with docker installed.

But, if this is only a one-time thing, you can also just execute the same script (e.g. in Python or bash/powershell) locally on your machine to do the same thing.