If you copy the primary index records and settings between apps with the Algolia CLI, the virtual replicas of the primary index will also be copied over to the destination app with their original replica names. Regardless of whether you copy the primary index using a different name, the virtual replica will always remain a virtual replica of the primary index.
For instance, you can use the Algolia CLI to copy the index "queso" from one app to another and rename it as "test-queso":
algolia objects browse queso -p <profile1> \
| algolia objects import test-queso -p <profile2> -F -
After that, you can proceed to copy its settings:
algolia settings get queso -p <profile1> \
| algolia settings import test-queso -p <profile2> -F -
At this point, both the primary index and its replica have been successfully copied from <profile1> (source app) to <profile2> (destination app).
"test-queso" (primary index)
"quesy-vr" (virtual replica)
The dashboard of the "quesy-vr" virtual replica index also indicates that it is a virtual replica of the "test-queso" index.