[moving this question to the user@ list...]

Just to be clear: does the 'keyPairList' in your example contain the correct *public* keys? Or are no keys returned at all?

ap

Quoting Jayant Kaushal <[email protected]>:

I am trying to fetch the existing key pairs from jclouds api.
but the private key comes null from server.

KeyPairApi keyPairApi =
getNovaApi(computeService).getKeyPairExtensionForZone(regionName).get();
    FluentIterable<? extends KeyPair> keyPairsList = keyPairApi.list();

    keyPairsList = keyPairApi.list();
    if(keyPairsList != null && keyPairsList.size() > 0) {
      for(KeyPair keys : keyPairsList) {
       keys.privateKey() // prints as null.
        }
      }
    }

Any Help

Regards
Jayant Kaushal

Reply via email to