code: def deploy(self, *lambdas):
          
  
          if not self.role:
              logger.error('Missing AWS Role')
              raise ArgumentsError('Role required')
  
          logger.debug('Deploying lambda {}'.format(self.lambda_name))
          zfh = self.package()
  
          if self.lambda_name in self.get_function_names():
              logger.info('Updating {} lambda'.format(self.lambda_name))
  
              response = self.client.update_function_code(
                  FunctionName=self.lambda_name,
                  ZipFile=zfh.getvalue(),
                  Publish=True
              )
          else:
              logger.info('Adding new {} lambda'.format(self.lambda_name))
  
              response = self.client.create_function(
                  FunctionName=self.lambda_name,
                  Runtime=yaep.env(
                      'LAMBDA_RUNTIME',
                      'python2.7'
                  ),
                  Role=self.role,
                  Handler=yaep.env(
                      'LAMBDA_HANDLER',
                      'lambda_function.lambda_handler'
                  ),
                  Code={
                      'ZipFile': zfh.getvalue(),
                  },
                  Description=yaep.env(
                      'LAMBDA_DESCRIPTION',
                      'Lambda code for {}'.format(self.lambda_name)
                  ),
                  Timeout=yaep.env(
                      'LAMBDA_TIMEOUT',
                      3,
                      convert_booleans=False,
                      type_class=int
                  ),
                  MemorySize=yaep.env(
                      'LAMBDA_MEMORY_SIZE',
                      128,
                      convert_booleans=False,
                      type_class=int
                  ),
                  Publish=True
              )
  
          status_code = response.get(
              'ResponseMetadata', {}
          ).get('HTTPStatusCode')
  
          if status_code in [200, 201]:
              logger.info('Successfully deployed {} version {}'.format(
                  self.lambda_name,
                  response.get('Version', 'Unkown')
              ))
          else:
              logger.error('Error deploying {}: {}'.format(
                  self.lambda_name,
                  response
              ))
docs: Deploys lambdas to AWS