Managing Registries using CLI

Hi, I am working on Jenkins driven automated process of:
Step 1. creation of environment
Step 2. provisioning hosts in EC2
Step 3. deploying containers using rancher-compose/docker-compose

using rancher CLI.

Since our docker images are in custom registry (ECR) …
how can i dynamically add new Registry to a newly created environment using CLI?

Ok, found a workaround instructions just by using Rancher API

http://forums.rancher.com/t/add-a-registry-via-the-api/2983/4