Commit 3b986164 authored by Alonso Ibarra, Juncal's avatar Alonso Ibarra, Juncal

Violation Handlers M24 added

parent 1e4581b6

Too many changes to show.

To preserve performance only 1000 of 1000+ files are displayed.

FROM tiangolo/uwsgi-nginx-flask:python3.6
RUN apt-get update && apt-get install unzip && apt-get install -y vim && wget https://releases.hashicorp.com/terraform/0.10.7/terraform_0.10.7_linux_amd64.zip?_ga=2.121414664.102068769.1507033863-2054770415.1501495729 -O temp.zip && unzip temp.zip -d /usr/local/bin && rm temp.zip && mkdir -p /app/repo && mkdir -p /home/ubuntu/terraform/certs && mkdir -p /home/ubuntu/terraform/scripts && mkdir /home/ubuntu/terraform/keypairs && pip install flask-restplus && pip install -U flask-cors && pip install pymongo==3.7 && pip install jsonschema==3.0.0a3 && wget http://security.debian.org/debian-security/pool/updates/main/o/openssl/libssl1.0.0_1.0.1t-1+deb8u9_amd64.deb && dpkg -i libssl1.0.0_1.0.1t-1+deb8u9_amd64.deb && wget https://fastdl.mongodb.org/linux/mongodb-linux-x86_64-ubuntu1604-4.0.0.tgz && tar -zxvf mongodb-linux-*-4.0.0.tgz && mkdir -p /data/db && export PATH=mongodb-linux-x86_64-ubuntu1604-4.0.0/bin:$PATH && cp mongodb-linux-x86_64-ubuntu1604-4.0.0/bin/* /usr/local/bin
COPY app/ /app/
COPY tfplugin/terraform-provider-cloudbroker /usr/local/bin
COPY scripts /home/ubuntu/terraform/scripts
COPY mongo.conf /etc/supervisor/conf.d
ENV STATIC_INDEX 1
conn = new Mongo();
print("Getting db 'adapt-do-db'")
db = conn.getDB("adapt-do-db");
print("Removing vm list");
db.vmList.remove({})
print("Removing vm status");
db.vmStatus.remove({})
\ No newline at end of file
#!/bin/bash
rm -r ExampleApp*
rm -r vm*
rm -r operations*
mongo clean-mongodb.js
This diff is collapsed.
variable "adapt_host" {
description = "The endpoint of ADAPT"
}
variable "cloudbroker_endpoint" {
description = "The endpoint of the cloudbroker API"
default = "https://decide-prototype.cloudbroker.com"
}
variable "cloudbroker_username" {
description = "The username for the cloudbroker API"
}
variable "cloudbroker_password" {
description = "The password for the cloudbroker API"
}
variable "vm_software_id" {
default = "21b7ebed-5076-43b6-8351-0e06cf16eedc"
}
variable "vm_resource_id" {
default = "18d07329-07f6-4d59-b1c1-676f64d1663f"
}
variable "vm_region_id" {
default = "4265ddb9-e862-4814-82a4-d6b92f25e8e5"
}
variable "vm_user" {
default = "ubuntu"
}
variable "instance_type_id" {
default = "e3ca8e4c-0f91-4e83-9bd9-4cef88d054a8"
}
variable "key_pair_id" {
default = "fb40a1f3-86b1-4e68-9ab3-049b664139e7"
}
variable "opened_port" {
default = "22,80,8000-9000,9411"
}
variable "consul-join-ip" {
}
variable "docker-private-registry-ip" {
default = ""
}
variable "docker-private-registry-port" {
default = ""
}
variable "node_name" {
}
variable "app_name" {
default = ""
}
provider "cloudbroker" {
username = "${var.cloudbroker_username}"
password = "${var.cloudbroker_password}"
endpoint = "${var.cloudbroker_endpoint}"
timeout = 60
max_retries = 5
}
resource "cloudbroker_instance" "decide-vm" {
software_id = "${var.vm_software_id}"
resource_id = "${var.vm_resource_id}"
region_id = "${var.vm_region_id}"
instance_type_id = "${var.instance_type_id}"
vm_user = "${var.vm_user}"
isolated = "false"
key_pair_id = "${var.key_pair_id}"
disable_autostop = "true"
opened_port = "${var.opened_port}"
name = "${var.node_name}"
provisioner "local-exec" {
command = "echo