def _put_bucket_lifecycle(self):
        """Adds bucket lifecycle configuration."""
        status = 'deleted'
        if self.s3props['lifecycle']['enabled']:
            lifecycle_config = {
                'Rules': self.s3props['lifecycle']['lifecycle_rules']
            }
            LOG.debug('Lifecycle Config: %s', lifecycle_config)
            _response = self.s3client.put_bucket_lifecycle_configuration(Bucket=self.bucket,
                                                                         LifecycleConfiguration=lifecycle_config)
            status = 'applied'
        else:
            _response = self.s3client.delete_bucket_lifecycle(Bucket=self.bucket)
        LOG.debug('Response setting up S3 lifecycle: %s', _response)
        LOG.info('S3 lifecycle configuration %s', status)
Adds bucket lifecycle configuration.