Skip to content
This repository has been archived by the owner on Apr 27, 2022. It is now read-only.

Commit

Permalink
Allow imaging of non-active instances
Browse files Browse the repository at this point in the history
  • Loading branch information
steve-gregory committed Oct 4, 2017
1 parent c64c1c7 commit 079c364
Show file tree
Hide file tree
Showing 4 changed files with 10 additions and 6 deletions.
1 change: 1 addition & 0 deletions api/v2/serializers/details/machine_request.py
Original file line number Diff line number Diff line change
Expand Up @@ -154,6 +154,7 @@ class Meta:
'new_application_description',
'new_application_visibility',
'new_application_access_list',
'access_list',
'system_files',
'installed_software',
'exclude_files',
Expand Down
10 changes: 5 additions & 5 deletions dev_requirements.txt
Original file line number Diff line number Diff line change
Expand Up @@ -4,12 +4,12 @@
#
# pip-compile --output-file dev_requirements.txt dev_requirements.in requirements.txt
#
amqp==2.2.1
amqp==2.2.2
ansible==2.3.2.0
apache-libcloud==0.20.1
appdirs==1.4.3
asn1crypto==0.22.0
babel==2.3.4
babel==2.5.1
backports-abc==0.5
backports.shutil-get-terminal-size==1.0.0 # via ipython
backports.ssl-match-hostname==3.5.0.1
Expand All @@ -25,7 +25,7 @@ celery==4.0.2
certifi==2017.7.27.1
cffi==1.10.0
chardet==3.0.4
chromogenic==0.4.13
chromogenic==0.4.15
cliff==2.8.0
cmd2==0.7.5
colorama==0.3.9
Expand Down Expand Up @@ -163,14 +163,14 @@ selenium==3.5.0 # via splinter
simplegeneric==0.8.1 # via ipython
simplejson==3.11.1
singledispatch==3.4.0.3
six==1.10.0
six==1.11.0
smmap2==2.0.3 # via gitdb2
splinter==0.7.6 # via behaving
sqlparse==0.2.3 # via django-debug-toolbar
stevedore==1.25.0
subspace==0.5.1
threepio==0.2.0
tornado==4.5.1
tornado==4.5.2
traitlets==4.3.2 # via ipython
unicodecsv==0.14.1
urllib3==1.22
Expand Down
2 changes: 1 addition & 1 deletion requirements.txt
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ celery==4.0.2
certifi==2017.7.27.1 # via requests, tornado
cffi==1.10.0 # via bcrypt, cryptography, pynacl
chardet==3.0.4 # via requests
chromogenic==0.4.13
chromogenic==0.4.15
cliff==2.8.0 # via osc-lib, python-neutronclient, python-openstackclient
cmd2==0.7.5 # via cliff
colorama==0.3.9
Expand Down
3 changes: 3 additions & 0 deletions service/tasks/machine.py
Original file line number Diff line number Diff line change
Expand Up @@ -401,6 +401,9 @@ def prep_instance_for_snapshot(identity_id, instance_id, **celery_task_args):
username = identity.created_by.username
driver = get_esh_driver(identity)
instance = driver.get_instance(instance_id)
if instance.extra.get('status','') != 'active':
celery_logger.info("prep_instance_for_snapshot skipped")
return
playbooks = deploy_prepare_snapshot(
instance.ip, username, instance_id)
celery_logger.info(playbooks.__dict__)
Expand Down

0 comments on commit 079c364

Please sign in to comment.