Example #1
0
 def _initialize_clouds(self):
     """Creates cloud credentials for the user"""
     self.data['cloudmesh']['clouds'] = {}
     cloudlist = self.active()
     for cloud in cloudlist:
         cloudcreds_handler = cloudmesh_cloud_handler(cloud)
         cloudcreds = cloudcreds_handler(self.profile(), self.projects('default'), self.projects('active'), cloud, self.clouddata[cloud])
         ########### for testing #############################################################
         # cloudcreds._client = mock_keystone.Client
         # cloudcreds._client.mockusername = self.data['cloudmesh']['profile']['username']
         # cloudcreds._client.mocktenants = ['fg82','fg110','fg296']
         #####################################################################################
         cloudcreds.initialize_cloud_user()
         self.data['cloudmesh']['clouds'][cloud] = cloudcreds.data
Example #2
0
 def change_own_password(self, oldpass, newpass):
     cloudlist = self.active()
     for cloud in cloudlist:
         cloudcreds_handler = cloudmesh_cloud_handler(cloud)
         cloudcreds = cloudcreds_handler(self.profile(), self.projects('default'), self.projects('active'), cloud, self.clouddata[cloud])
         cloudcreds.change_password(oldpass, newpass)