GEODE-2421: Adding packer portion of making a VS2015 dev AMI

This closes #384


Project: http://git-wip-us.apache.org/repos/asf/geode-native/repo
Commit: http://git-wip-us.apache.org/repos/asf/geode-native/commit/340f2fca
Tree: http://git-wip-us.apache.org/repos/asf/geode-native/tree/340f2fca
Diff: http://git-wip-us.apache.org/repos/asf/geode-native/diff/340f2fca

Branch: refs/heads/master
Commit: 340f2fca80d9388155ed0911712f9a830211b32b
Parents: e79c407
Author: Ernest Burghardt <[email protected]>
Authored: Thu Feb 2 14:03:10 2017 -0800
Committer: Dan Smith <[email protected]>
Committed: Thu Feb 2 14:24:20 2017 -0800

----------------------------------------------------------------------
 packer/windows-2012-vs-2015.json             | 64 +++++++++++++++++++++++
 packer/windows/install-vs-2015-community.ps1 |  9 ++++
 2 files changed, 73 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/geode-native/blob/340f2fca/packer/windows-2012-vs-2015.json
----------------------------------------------------------------------
diff --git a/packer/windows-2012-vs-2015.json b/packer/windows-2012-vs-2015.json
new file mode 100644
index 0000000..da82b94
--- /dev/null
+++ b/packer/windows-2012-vs-2015.json
@@ -0,0 +1,64 @@
+{
+  "variables":{
+    "region":"us-west-2",
+    "source_ami":"ami-ac5395cc",
+    "source_image_name":"X.vmx",
+    "image_name":"windows-2012-vs-2015"
+  },
+  "builders":[
+    {
+      "type":"amazon-ebs",
+      "instance_type":"t2.large",
+      "ami_name":"native-{{user `version`}}-{{user `image_name`}} 
{{timestamp}}",
+      "access_key":"{{user `aws_access_key`}}",
+      "secret_key":"{{user `aws_secret_key`}}",
+      "region":"{{user `region`}}",
+      "source_ami":"{{user `source_ami`}}",
+      "subnet_id":"{{user `subnet_id`}}",
+      "vpc_id":"{{user `vpc_id`}}",
+      "tags":{
+        "team":"native",
+        "version":"{{user `version`}}",
+        "source_ami":"{{user `source_ami`}}"
+      },
+      "communicator":"winrm",
+      "winrm_username":"Administrator",
+      "launch_block_device_mappings":[
+        {
+          "device_name":"/dev/sda1",
+          "delete_on_termination":true,
+          "volume_size":60
+        }
+      ]
+    }
+  ],
+  "provisioners":[
+    {
+      "pause_before":"30s",
+      "type":"file",
+      "source":"windows/Packer.psm1",
+      "destination":"Documents/WindowsPowerShell/Modules/Packer/Packer.psm1"
+    },
+    {
+      "type":"powershell",
+      "scripts":[
+        "windows/install-vs-2015-community.ps1"
+      ]
+    },
+    {
+      "type":"powershell",
+      "scripts":[
+        "windows/cleanup.ps1"
+      ]
+    },
+    {
+      "type":"powershell",
+      "scripts":[
+        "windows/setup-ec2config.ps1"
+      ],
+      "only":[
+        "amazon-ebs"
+      ]
+    }
+  ]
+}

http://git-wip-us.apache.org/repos/asf/geode-native/blob/340f2fca/packer/windows/install-vs-2015-community.ps1
----------------------------------------------------------------------
diff --git a/packer/windows/install-vs-2015-community.ps1 
b/packer/windows/install-vs-2015-community.ps1
new file mode 100644
index 0000000..c175410
--- /dev/null
+++ b/packer/windows/install-vs-2015-community.ps1
@@ -0,0 +1,9 @@
+# TODO AdminDeploy.xml
+# vs_community.exe /AdminFile C:\Users\Administrator\AdminDeployment.xml /Log 
setup.log /Passive
+Set-PSDebug -Trace 0
+
+Import-Module Packer
+
+$log = "vs_community.log"
+
+choco install visualstudio2015community -confirm

Reply via email to