You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@dlab.apache.org by dm...@apache.org on 2019/10/28 10:26:14 UTC

[incubator-dlab] branch DLAB-1106 created (now e008b50)

This is an automated email from the ASF dual-hosted git repository.

dmysakovets pushed a change to branch DLAB-1106
in repository https://gitbox.apache.org/repos/asf/incubator-dlab.git.


      at e008b50  [DLAB-1106] Added missing shared_image_enabled conditional to dataengine[AWS/Azure]

This branch includes the following new commits:

     new e008b50  [DLAB-1106] Added missing shared_image_enabled conditional to dataengine[AWS/Azure]

The 1 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails.  The revisions
listed as "add" were already present in the repository and have only
been added to this reference.



---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@dlab.apache.org
For additional commands, e-mail: commits-help@dlab.apache.org


[incubator-dlab] 01/01: [DLAB-1106] Added missing shared_image_enabled conditional to dataengine[AWS/Azure]

Posted by dm...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

dmysakovets pushed a commit to branch DLAB-1106
in repository https://gitbox.apache.org/repos/asf/incubator-dlab.git

commit e008b502c00cd7e51561410dfdacd9b35153050b
Author: Demyan Mysakovets <de...@gmail.com>
AuthorDate: Mon Oct 28 12:25:51 2019 +0200

    [DLAB-1106] Added missing shared_image_enabled conditional to dataengine[AWS/Azure]
---
 .../src/general/scripts/aws/dataengine_prepare.py        | 13 +++++++++----
 .../src/general/scripts/azure/dataengine_prepare.py      | 16 +++++++++++-----
 2 files changed, 20 insertions(+), 9 deletions(-)

diff --git a/infrastructure-provisioning/src/general/scripts/aws/dataengine_prepare.py b/infrastructure-provisioning/src/general/scripts/aws/dataengine_prepare.py
index 642198e..0cefaeb 100644
--- a/infrastructure-provisioning/src/general/scripts/aws/dataengine_prepare.py
+++ b/infrastructure-provisioning/src/general/scripts/aws/dataengine_prepare.py
@@ -102,10 +102,15 @@ if __name__ == "__main__":
         data_engine['primary_disk_size'] = '30'
         data_engine['instance_class'] = 'dataengine'
 
-        data_engine['expected_image_name'] = '{0}-{1}-{2}-{3}-notebook-image'.format(data_engine['service_base_name'],
-                                                                           os.environ['endpoint_name'],
-                                                                           os.environ['project_name'],
-                                                                           os.environ['application'])
+        if os.environ['conf_shared_image_enabled'] == 'false':
+            data_engine['expected_image_name'] = '{0}-{1}-{2}-{3}-notebook-image'.format(data_engine['service_base_name'],
+                                                                                         os.environ['endpoint_name'],
+                                                                                         os.environ['project_name'],
+                                                                                         os.environ['application'])
+        else:
+            data_engine['expected_image_name'] = '{0}-{1}-{2}-notebook-image'.format(data_engine['service_base_name'],
+                                                                                         os.environ['endpoint_name'],
+                                                                                         os.environ['application'])
         data_engine['notebook_image_name'] = (
             lambda x: '{0}-{1}-{2}-{3}'.format(data_engine['service_base_name'],
                                                os.environ['project_name'],
diff --git a/infrastructure-provisioning/src/general/scripts/azure/dataengine_prepare.py b/infrastructure-provisioning/src/general/scripts/azure/dataengine_prepare.py
index ace9499..24855fa 100644
--- a/infrastructure-provisioning/src/general/scripts/azure/dataengine_prepare.py
+++ b/infrastructure-provisioning/src/general/scripts/azure/dataengine_prepare.py
@@ -104,11 +104,17 @@ if __name__ == "__main__":
                                       os.environ['conf_billing_tag_key']: os.environ['conf_billing_tag_value']}
         data_engine['primary_disk_size'] = '32'
         data_engine['image_type'] = 'default'
-        data_engine['expected_image_name'] = '{0}-{1}-{2}-{3}-notebook-image'.format(
-            data_engine['service_base_name'],
-            data_engine['endpoint_name'],
-            data_engine['project_name'],
-            os.environ['application'])
+
+        if os.environ['conf_shared_image_enabled'] == 'false':
+            data_engine['expected_image_name'] = '{0}-{1}-{2}-{3}-notebook-image'.format(data_engine['service_base_name'],
+                                                                                         os.environ['endpoint_name'],
+                                                                                         os.environ['project_name'],
+                                                                                         os.environ['application'])
+        else:
+            data_engine['expected_image_name'] = '{0}-{1}-{2}-notebook-image'.format(data_engine['service_base_name'],
+                                                                                     os.environ['endpoint_name'],
+                                                                                     os.environ['application'])
+
         data_engine['notebook_image_name'] = (lambda x: os.environ['notebook_image_name'] if x != 'None'
                     else data_engine['expected_image_name'])(str(os.environ.get('notebook_image_name')))
 


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@dlab.apache.org
For additional commands, e-mail: commits-help@dlab.apache.org