You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@dlab.apache.org by lf...@apache.org on 2020/04/01 11:47:02 UTC

[incubator-dlab] branch DLAB-1664 created (now 794723f)

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

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


      at 794723f  [DLAB-1664]: added resource block to destroy AMIs per endpoint during endpoint termination

This branch includes the following new commits:

     new 794723f  [DLAB-1664]: added resource block to destroy AMIs per endpoint during endpoint termination

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-1664]: added resource block to destroy AMIs per endpoint during endpoint termination

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

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

commit 794723f7f5b422d21797fcf14f9485946d721767
Author: leonidfrolov <fr...@gmail.com>
AuthorDate: Wed Apr 1 14:37:51 2020 +0300

    [DLAB-1664]: added resource block to destroy AMIs per endpoint during endpoint termination
---
 .../terraform/aws/endpoint/main/ami.tf             | 28 ++++++++++++++++++++++
 .../terraform/aws/endpoint/main/variables.tf       |  5 ++++
 2 files changed, 33 insertions(+)

diff --git a/infrastructure-provisioning/terraform/aws/endpoint/main/ami.tf b/infrastructure-provisioning/terraform/aws/endpoint/main/ami.tf
new file mode 100644
index 0000000..007afb1
--- /dev/null
+++ b/infrastructure-provisioning/terraform/aws/endpoint/main/ami.tf
@@ -0,0 +1,28 @@
+# *****************************************************************************
+ #
+ # Licensed to the Apache Software Foundation (ASF) under one
+ # or more contributor license agreements.  See the NOTICE file
+ # distributed with this work for additional information
+ # regarding copyright ownership.  The ASF licenses this file
+ # to you under the Apache License, Version 2.0 (the
+ # "License"); you may not use this file except in compliance
+ # with the License.  You may obtain a copy of the License at
+ #
+ #   http://www.apache.org/licenses/LICENSE-2.0
+ #
+ # Unless required by applicable law or agreed to in writing,
+ # software distributed under the License is distributed on an
+ # "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ # KIND, either express or implied.  See the License for the
+ # specific language governing permissions and limitations
+ # under the License.
+ #
+ # ******************************************************************************
+
+ resource "aws_ami" "shared_notebook_ami" {
+   for_each = var.application_name
+   name = "${var.service_base_name}-${var.endpoint_id}-${var.application_name}-notebook-image"
+   virtualization_type = "hvm"
+   root_device_name    = "/dev/sda1"
+   force_destroy = true
+ }
\ No newline at end of file
diff --git a/infrastructure-provisioning/terraform/aws/endpoint/main/variables.tf b/infrastructure-provisioning/terraform/aws/endpoint/main/variables.tf
index 8dc3d77..a6ffbbb 100644
--- a/infrastructure-provisioning/terraform/aws/endpoint/main/variables.tf
+++ b/infrastructure-provisioning/terraform/aws/endpoint/main/variables.tf
@@ -80,4 +80,9 @@ variable "additional_tag" {
 
 variable "tag_resource_id" {
   default = "user:tag"
+}
+
+variable "application_name" {
+  type    = list(string)
+  default = ["jupyterlab", "jupyter", "rstudio", "tensor", "zeppelin", "deeplearning", "tensor-rstudio", "superset"]
 }
\ No newline at end of file


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