Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

WIP: Heat provisioner #10

Closed
wants to merge 17 commits into from
Closed

WIP: Heat provisioner #10

wants to merge 17 commits into from

Conversation

tomkukral
Copy link
Contributor

Add support for Heat provisioner

Copy link
Contributor Author

@tomkukral tomkukral left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Good job, thanks. Can you add requirements?

I'll think about ways to test this code.

from keystoneauth1.identity import v3
from keystoneauth1 import session
import heatclient
import heatclient.client
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can you plesae add these dependencies to requirements.txt file?

Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

See latest commit

@tomkukral tomkukral changed the title Heat provisioner WIP: Heat provisioner Oct 6, 2017
if cacheEnabled and cache.get(cluster_id):
return cache.get(cluster_id)

if cluster_id in self.clusters:
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

you can negate here, so it will be

if clusterd_id not in self.clusters:
  logger.error('Cluster {} not managed by this provisioner'.format(cluster_id))
  return None

and continue with less nesting.

return self.clusters

def delete(self, cluster_id):
if cluster_id in self.clusters:
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

again if you negate and return code will be much easier to read


try:
# Create stack
r = self.__create_stack(stack_name, template, merged_files, merged_env)
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

is the 'r' used somewhere? also do not use one letter names.

from heatclient.common import template_utils

import logging
from werkzeug.contrib.cache import SimpleCache
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

import are wrongly ordered

@naumvd95 naumvd95 added the WIP label May 4, 2018
@naumvd95 naumvd95 added TBD and removed WIP labels May 13, 2018
@naumvd95 naumvd95 added the backlog delayed fixes/features label Jul 2, 2018
ekhomyakova pushed a commit that referenced this pull request Sep 4, 2018
ekhomyakova pushed a commit that referenced this pull request Sep 4, 2018
@tomkukral tomkukral closed this Sep 25, 2018
@naumvd95 naumvd95 deleted the heat-provisioner branch September 25, 2018 07:43
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
backlog delayed fixes/features TBD
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants