There is another PR on these packer scripts. I'm going to go ahead and
merge the changes, given that it sounds like we're working towards a readme
and making these scripts useful to everyone in the community. If there are
objections, I can stop accepting these PRs.

-Dan

On Thu, Feb 2, 2017 at 7:47 PM, William Markito Oliveira <
william.mark...@gmail.com> wrote:

> +1 for packer scripts. With Jake's readme everyone should be able to use
> it as a standard way to build environment for the native client.
>
> Thanks for sharing that!
>
> Sent from my iPhone
>
> > On Feb 2, 2017, at 7:20 PM, Michael Martell <mmart...@pivotal.io> wrote:
> >
> > For those unfamiliar with packer, or looking for the simplest path to
> > building and learning the code, it may be advantageous to post the steps
> > for each platform. Personally, I like to learn new code by stepping thru
> > examples in the debugger. I'd be happy to post my setup for debugging the
> > Geode C++ client on Windows 10 with Visual Studio and OSX with Xcode.
> >
> > Mike
> >
> >> On Thu, Feb 2, 2017 at 4:41 PM Jacob Barrett <jbarr...@pivotal.io>
> wrote:
> >>
> >> I have a readme started that I will commit when I am back from vacation
> in
> >> a week.
> >> On Thu, Feb 2, 2017 at 4:36 PM Anthony Baker <aba...@pivotal.io> wrote:
> >>
> >>> +1 for a README
> >>>
> >>> I started on a Dockerfile so we could run a job on builds.apache.org.
> I
> >>> haven’t been able to get back to it recently but here’s a rough draft:
> >>>
> >>> FROM ubuntu
> >>> MAINTAINER Apache Geode Geode <dev@geode.apache.org>
> >>>
> >>> ARG GEODE_VERSION
> >>>
> >>> RUN \
> >>>  apt-get update && \
> >>>  apt-get -y upgrade && \
> >>>  apt-get install -y build-essential && \
> >>>  apt-get install -y cmake && \
> >>>  apt-get install -y doxygen && \
> >>>  apt-get install -y git && \
> >>>  apt-get install -y openjdk-8-jdk && \
> >>>  apt-get install -y wget && \
> >>>  apt-get install -y zlib1g-dev && \
> >>>  rm -rf /var/lib/apt/lists/*
> >>>
> >>> RUN \
> >>>  wget
> >>>
> >> https://builds.apache.org/job/Geode-nightly/
> lastSuccessfulBuild/artifact/geode-assembly/build/
> distributions/apache-geode-${GEODE_VERSION}.tar.gz
> >>> && \
> >>>  tar xzf apache-geode-${GEODE_VERSION}.tar.gz && \
> >>>  ls /
> >>>  #rm apache-geode-${GEODE_VERSION.tar}.tar.gz
> >>>
> >>> ENV GEODE /apache-geode-${GEODE_VERSION}
> >>> ENV JAVA_HOME /usr/lib/jvm/java-8-openjdk-amd64
> >>>
> >>> CMD ["bash"]
> >>>
> >>>
> >>> As far as releases go, I think we should start with a source-only
> release
> >>> (after all that’s the only *officially* recognized artifact anyway).
> If
> >> we
> >>> want to create binary convenience artifacts for a release, I would be
> >>> hesitant to go beyond linux because multi-platforms builds impose a
> large
> >>> burden on the Release Manager.
> >>>
> >>> Anthony
> >>>
> >>>> On Feb 2, 2017, at 4:26 PM, Dan Smith <dsm...@pivotal.io> wrote:
> >>>>
> >>>> It does seem like this stuff needs a README on how to use it.
> >>>>
> >>>> Are we going to need these images do a release of the native client
> >> code?
> >>>> How many of these platforms will we need to build on to release the
> >>> native
> >>>> client?
> >>>>
> >>>> -Dan
> >>>>
> >>>> On Thu, Feb 2, 2017 at 3:43 PM, Jacob Barrett <jbarr...@pivotal.io>
> >>> wrote:
> >>>>
> >>>>> Think of it as a Dockerfile for things not Docker, like Solaris and
> >>>>> Windows. It describes and can build a machine capable of compile or
> >>>>> developing the native client. The toolchain is slightly more
> >> complicated
> >>>>> than the Java side. Currently the Packer files are implemented for
> AWS
> >>> but
> >>>>> can easily be modified to support other virtualization platforms like
> >>>>> VMWare, OpenStack, etc.
> >>>>>
> >>>>> -Jake
> >>>>>
> >>>>>
> >>>>> On Thu, Feb 2, 2017 at 3:38 PM Ernest Burghardt <
> >> eburgha...@pivotal.io>
> >>>>> wrote:
> >>>>>
> >>>>>> Hi Mark,
> >>>>>>
> >>>>>> Our thinking was to make our packer (and associated) scripts
> >> available
> >>>>> such
> >>>>>> that a community member could use them to create a VM that would be
> >>> very
> >>>>>> equivalent to our build environment.
> >>>>>> There is some info/documentation that would need to be created to
> >> show
> >>>>> how
> >>>>>> to do this, but it should be possible for an individual to make
> >> images
> >>>>> like
> >>>>>> we do in our pipeline.
> >>>>>>
> >>>>>> Best,
> >>>>>> Ernie
> >>>>>>
> >>>>>> On Thu, Feb 2, 2017 at 3:07 PM, Mark Bretl <mbr...@apache.org>
> >> wrote:
> >>>>>>
> >>>>>>> Hi,
> >>>>>>>
> >>>>>>> How does/will this help the community?
> >>>>>>>
> >>>>>>> --Mark
> >>>>>>>
> >>>>>>>> On Thu, Feb 2, 2017 at 2:25 PM, <upthewatersp...@apache.org>
> wrote:
> >>>>>>>>
> >>>>>>>> Repository: geode
> >>>>>>>> Updated Branches:
> >>>>>>>> refs/heads/next-gen-native-client-software-grant e79c4072b ->
> >>>>>>> 340f2fca8
> >>>>>>>>
> >>>>>>>>
> >>>>>>>> GEODE-2421: Adding packer portion of making a VS2015 dev AMI
> >>>>>>>>
> >>>>>>>> This closes #384
> >>>>>>>>
> >>>>>>>>
> >>>>>>>> Project: http://git-wip-us.apache.org/repos/asf/geode/repo
> >>>>>>>> Commit:
> >> http://git-wip-us.apache.org/repos/asf/geode/commit/340f2fca
> >>>>>>>> Tree: http://git-wip-us.apache.org/repos/asf/geode/tree/340f2fca
> >>>>>>>> Diff: http://git-wip-us.apache.org/repos/asf/geode/diff/340f2fca
> >>>>>>>>
> >>>>>>>> Branch: refs/heads/next-gen-native-client-software-grant
> >>>>>>>> Commit: 340f2fca80d9388155ed0911712f9a830211b32b
> >>>>>>>> Parents: e79c407
> >>>>>>>> Author: Ernest Burghardt <eburgha...@pivotal.io>
> >>>>>>>> Authored: Thu Feb 2 14:03:10 2017 -0800
> >>>>>>>> Committer: Dan Smith <upthewatersp...@apache.org>
> >>>>>>>> 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/blob/340f2fca/p
> >>>>>>>> acker/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/blob/340f2fca/p
> >>>>>>>> acker/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