Hammr Project Update: Machine Images and Docker Containers for your Cloud, OW2con'16, Paris.
-
Upload
ow2-consortium -
Category
Technology
-
view
96 -
download
2
Transcript of Hammr Project Update: Machine Images and Docker Containers for your Cloud, OW2con'16, Paris.
![Page 1: Hammr Project Update: Machine Images and Docker Containers for your Cloud, OW2con'16, Paris.](https://reader031.fdocuments.in/reader031/viewer/2022022410/58e56c811a28abd82b8b580b/html5/thumbnails/1.jpg)
Copyright © UShareSoft 2016 Copyright © UShareSoft 2016
Look Beyond the Cloud
Hammr Project Update: Machine Images and DockerContainers for your Cloud
Joris Bremond, Software Development Engineer, UShareSoftAlexandre Lefebvre, Professional Services, UShareSoft
![Page 2: Hammr Project Update: Machine Images and Docker Containers for your Cloud, OW2con'16, Paris.](https://reader031.fdocuments.in/reader031/viewer/2022022410/58e56c811a28abd82b8b580b/html5/thumbnails/2.jpg)
22
© Copyright 2016 UShareSoft© Copyright 2016 UShareSoft
What is ?
![Page 3: Hammr Project Update: Machine Images and Docker Containers for your Cloud, OW2con'16, Paris.](https://reader031.fdocuments.in/reader031/viewer/2022022410/58e56c811a28abd82b8b580b/html5/thumbnails/3.jpg)
33
© Copyright 2016 UShareSoft© Copyright 2016 UShareSoft
Hammr Command-Line Tool
Hammr Command-line Tool: Consistent Machine Images from a Single Configuration FileHammr Command-line Tool: Consistent Machine Images from a Single Configuration File
> Open source OW2 project> command-line tool written in Python> http://www.ow2.org/bin/view/ActivitiesDashboard/hammr –
www.hammr.io> Github: https://github.com/usharesoft/hammr
> Open source OW2 project> command-line tool written in Python> http://www.ow2.org/bin/view/ActivitiesDashboard/hammr –
www.hammr.io> Github: https://github.com/usharesoft/hammr
![Page 4: Hammr Project Update: Machine Images and Docker Containers for your Cloud, OW2con'16, Paris.](https://reader031.fdocuments.in/reader031/viewer/2022022410/58e56c811a28abd82b8b580b/html5/thumbnails/4.jpg)
44
© Copyright 2016 UShareSoft© Copyright 2016 UShareSoft
Hammr overall architecture
![Page 5: Hammr Project Update: Machine Images and Docker Containers for your Cloud, OW2con'16, Paris.](https://reader031.fdocuments.in/reader031/viewer/2022022410/58e56c811a28abd82b8b580b/html5/thumbnails/5.jpg)
55
© Copyright 2016 UShareSoft© Copyright 2016 UShareSoft
Installing hammr
Installing Hammr
Install Hammr system dependencies first, then
Installing Hammr
Install Hammr system dependencies first, then
$ pip install hammr
$ hammr –v
hammr version '0.2.5.10'
$ pip install hammr
$ hammr –v
hammr version '0.2.5.10'
Help MenuHelp Menu
$ hammr --help$ hammr --help
![Page 6: Hammr Project Update: Machine Images and Docker Containers for your Cloud, OW2con'16, Paris.](https://reader031.fdocuments.in/reader031/viewer/2022022410/58e56c811a28abd82b8b580b/html5/thumbnails/6.jpg)
66
© Copyright 2016 UShareSoft© Copyright 2016 UShareSoft
Creating &Managing your
Stackswith
![Page 7: Hammr Project Update: Machine Images and Docker Containers for your Cloud, OW2con'16, Paris.](https://reader031.fdocuments.in/reader031/viewer/2022022410/58e56c811a28abd82b8b580b/html5/thumbnails/7.jpg)
77
© Copyright 2016 UShareSoft© Copyright 2016 UShareSoft
Getting Started with Hammr
> Template file: configuration file (Yaml or Json)> Describe your application stack using the stack keyword
> Generate machine or containers images by defining builders
> Publish the generated machine images using your cloud credentials
or download its to your computer
> Template file: configuration file (Yaml or Json)> Describe your application stack using the stack keyword
> Generate machine or containers images by defining builders
> Publish the generated machine images using your cloud credentials
or download its to your computer
![Page 8: Hammr Project Update: Machine Images and Docker Containers for your Cloud, OW2con'16, Paris.](https://reader031.fdocuments.in/reader031/viewer/2022022410/58e56c811a28abd82b8b580b/html5/thumbnails/8.jpg)
88
© Copyright 2016 UShareSoft© Copyright 2016 UShareSoft
Defining your Stack: nginx Example
$ vi nginx-template.yaml
---
stack:
name: nginx
version: '1.0'
os:
name: Debian
version: '8'
arch: x86_64
profile: Minimal
pkgs:
- name: nginx
installation:
diskSize: 12288
$ vi nginx-template.yaml
---
stack:
name: nginx
version: '1.0'
os:
name: Debian
version: '8'
arch: x86_64
profile: Minimal
pkgs:
- name: nginx
installation:
diskSize: 12288
stack keyword defining the content of your stackstack keyword defining the content of your stack
os keyword defining the os profile and packagesos keyword defining the os profile and packages
installation keyword defining the “install” parametersinstallation keyword defining the “install” parameters
![Page 9: Hammr Project Update: Machine Images and Docker Containers for your Cloud, OW2con'16, Paris.](https://reader031.fdocuments.in/reader031/viewer/2022022410/58e56c811a28abd82b8b580b/html5/thumbnails/9.jpg)
99
© Copyright 2016 UShareSoft© Copyright 2016 UShareSoft
Hammr: Modeling the Stack from a Single File
Security parametersKernel ParametersPartitioningNetworkingKeyboard, TimezoneLicense Entitlement
Security parametersKernel ParametersPartitioningNetworkingKeyboard, TimezoneLicense Entitlement
JeOS ProfilingPackage Updates
OS Repository SearchPackage Time Machine
JeOS ProfilingPackage Updates
OS Repository SearchPackage Time Machine
Off-the-Shelf SoftwareComponents
Off-the-Shelf SoftwareComponents
Private Software CatalogPrivate Software Catalog
Configuration scriptsConfiguration scripts
![Page 10: Hammr Project Update: Machine Images and Docker Containers for your Cloud, OW2con'16, Paris.](https://reader031.fdocuments.in/reader031/viewer/2022022410/58e56c811a28abd82b8b580b/html5/thumbnails/10.jpg)
1010
© Copyright 2016 UShareSoft© Copyright 2016 UShareSoft
Creating the Template: nginx ExampleVerify the syntax: template validateVerify the syntax: template validate
$ hammr template validate --file nginx-template.yaml
Validating the template file [/Users/james/nginx-template.yaml] ...
OK: Syntax of template file [/Users/james/nginx-template.yaml] is ok
$ hammr template validate --file nginx-template.yaml
Validating the template file [/Users/james/nginx-template.yaml] ...
OK: Syntax of template file [/Users/james/nginx-template.yaml] is ok
Create the Template: template createCreate the Template: template create
$ hammr template create --file nginx-template.yamlValidating the template file [/Users/james/nginx-template.yaml] ...
OK: Syntax of template file [/Users/james/nginx-template.yaml] is ok
Creating template from temporary [/var/folders/f6/8kljm7cxgn/T/hammr-15888/archive.tar.gz] archive ...
100%|#############################################################################|
OK: Template create: DONE
Template URI: users/root/appliances/898
Template Id : 898
$ hammr template create --file nginx-template.yamlValidating the template file [/Users/james/nginx-template.yaml] ...
OK: Syntax of template file [/Users/james/nginx-template.yaml] is ok
Creating template from temporary [/var/folders/f6/8kljm7cxgn/T/hammr-15888/archive.tar.gz] archive ...
100%|#############################################################################|
OK: Template create: DONE
Template URI: users/root/appliances/898
Template Id : 898
![Page 11: Hammr Project Update: Machine Images and Docker Containers for your Cloud, OW2con'16, Paris.](https://reader031.fdocuments.in/reader031/viewer/2022022410/58e56c811a28abd82b8b580b/html5/thumbnails/11.jpg)
1111
© Copyright 2016 UShareSoft© Copyright 2016 UShareSoft
Listing Created Templates
List created templates: template listList created templates: template list
$ hammr template list
+-----+----------------------+---------+---------------------+---------------------+---------------------+--------+---------+
| Id | Name | Version | OS | Created | Last modified | # Imgs | Updates |
+=====+======================+=========+=====================+=====================+=====================+========+=========+
683 | nginx | 1.0 | Debian 8 x86_64 | 2016-05-02 13:59:25 | 2016-05-02 13:59:27 | 0 | 0 |
+-----+----------------------+---------+---------------------+---------------------+---------------------+--------+---------+
Found 1 templates
$ hammr template list
+-----+----------------------+---------+---------------------+---------------------+---------------------+--------+---------+
| Id | Name | Version | OS | Created | Last modified | # Imgs | Updates |
+=====+======================+=========+=====================+=====================+=====================+========+=========+
683 | nginx | 1.0 | Debian 8 x86_64 | 2016-05-02 13:59:25 | 2016-05-02 13:59:27 | 0 | 0 |
+-----+----------------------+---------+---------------------+---------------------+---------------------+--------+---------+
Found 1 templates
![Page 12: Hammr Project Update: Machine Images and Docker Containers for your Cloud, OW2con'16, Paris.](https://reader031.fdocuments.in/reader031/viewer/2022022410/58e56c811a28abd82b8b580b/html5/thumbnails/12.jpg)
1212
© Copyright 2016 UShareSoft© Copyright 2016 UShareSoft
Defining a Builder: Machine Image Format
$ vi nginx-template.yaml
---
...stack section omitted
builders:
- type: openstack
account:
file: "/home/joris/accounts/openstack-account.yaml"
tenant: opencloudware
image-name: test-nginx
description: joris test nginx image
$ vi nginx-template.yaml
---
...stack section omitted
builders:
- type: openstack
account:
file: "/home/joris/accounts/openstack-account.yaml"
tenant: opencloudware
image-name: test-nginx
description: joris test nginx image
builders keyword defining all the machineImages to buildbuilders keyword defining all the machineImages to buildImage formatImage format
Machine image registration informationMachine image registration informationCloud account credentialsCloud account credentials
![Page 13: Hammr Project Update: Machine Images and Docker Containers for your Cloud, OW2con'16, Paris.](https://reader031.fdocuments.in/reader031/viewer/2022022410/58e56c811a28abd82b8b580b/html5/thumbnails/13.jpg)
1313
© Copyright 2016 UShareSoft© Copyright 2016 UShareSoft
Defining a Builder: Publication Information
$ vi nginx-template.yaml
---
...stack section omitted
builders:
- type: openstack
account:
file: "/home/joris/accounts/openstack-account.yaml"
tenant: opencloudware
image-name: test-nginx
description: joris test nginx image
$ vi nginx-template.yaml
---
...stack section omitted
builders:
- type: openstack
account:
file: "/home/joris/accounts/openstack-account.yaml"
tenant: opencloudware
image-name: test-nginx
description: joris test nginx image
Cloud account credentialsCloud account credentials
$ vi openstack-account.yaml
---
accounts:
- type: openstack
name: My OpenStack Account
endpoint: http://ow2stack.org:9292/v1/
keystoneEndpoint: http://ow2stack.org:5000/v2.0
username: test
password: password
$ vi openstack-account.yaml
---
accounts:
- type: openstack
name: My OpenStack Account
endpoint: http://ow2stack.org:9292/v1/
keystoneEndpoint: http://ow2stack.org:5000/v2.0
username: test
password: password
![Page 14: Hammr Project Update: Machine Images and Docker Containers for your Cloud, OW2con'16, Paris.](https://reader031.fdocuments.in/reader031/viewer/2022022410/58e56c811a28abd82b8b580b/html5/thumbnails/14.jpg)
1414
© Copyright 2016 UShareSoft© Copyright 2016 UShareSoft
Generating Machine Image(s)
Create any cloud account first: account createCreate any cloud account first: account create
$ hammr account create --file openstack-account.yaml
Validating the template file [openstack-account.yaml] ...
OK: Syntax of template file [openstack-account.yaml] is ok
Create account for 'ow2stack'...
OK: Account create successfully for [openstack]
$ hammr account create --file openstack-account.yaml
Validating the template file [openstack-account.yaml] ...
OK: Syntax of template file [openstack-account.yaml] is ok
Create account for 'ow2stack'...
OK: Account create successfully for [openstack]
Generate the machine images: template build Generate the machine images: template build
$ hammr template build --file nginx-template.yaml
Validating the template file [nginx-template.yaml] ...
Generating 'openstack' image (1/1)
|>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>| 100%: Done, created on ... |<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<|
OK: Generation 'openstack' ok
Image URI: users/root/appliances/21/images/47
Image Id : 47
$ hammr template build --file nginx-template.yaml
Validating the template file [nginx-template.yaml] ...
Generating 'openstack' image (1/1)
|>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>| 100%: Done, created on ... |<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<|
OK: Generation 'openstack' ok
Image URI: users/root/appliances/21/images/47
Image Id : 47
Image ID: 47, used to register this generated machine image to the target cloud environmentImage ID: 47, used to register this generated machine image to the target cloud environment
![Page 15: Hammr Project Update: Machine Images and Docker Containers for your Cloud, OW2con'16, Paris.](https://reader031.fdocuments.in/reader031/viewer/2022022410/58e56c811a28abd82b8b580b/html5/thumbnails/15.jpg)
1515
© Copyright 2016 UShareSoft© Copyright 2016 UShareSoft
Publishing Machine Image(s)
Publishing the generated machine image: image publishPublishing the generated machine image: image publish
$ hammr image publish --id 47 --file nginx-template.yamlPublishing 'openstack' image (1/1)
|>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>| 100%: Done, published o... |<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<|
OK: Publication to 'ow2stack' is ok
Cloud ID : 37d20dba-7a1c-43f9-9c77-c05f60d3094c
$ hammr image publish --id 47 --file nginx-template.yamlPublishing 'openstack' image (1/1)
|>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>| 100%: Done, published o... |<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<|
OK: Publication to 'ow2stack' is ok
Cloud ID : 37d20dba-7a1c-43f9-9c77-c05f60d3094c
Listing Your Images: image list Listing Your Images: image list
$ hammr image list$ hammr image list
Cloud ID: used for provisioning instances on OpenStackCloud ID: used for provisioning instances on OpenStack
![Page 16: Hammr Project Update: Machine Images and Docker Containers for your Cloud, OW2con'16, Paris.](https://reader031.fdocuments.in/reader031/viewer/2022022410/58e56c811a28abd82b8b580b/html5/thumbnails/16.jpg)
1616
© Copyright 2016 UShareSoft© Copyright 2016 UShareSoft
Supported Target Machine Image Formats
> ISO> ISO > Hyper-V
> KVM
> Raw
> QCOW2
> Vagrant
> VirtualBox
> VHD
> VMware Workstation
> VMware ESXi
> VMware vCenter vSphere
> Xen
> Hyper-V
> KVM
> Raw
> QCOW2
> Vagrant
> VirtualBox
> VHD
> VMware Workstation
> VMware ESXi
> VMware vCenter vSphere
> Xen
> Abiquo
> AWS (EC2)
> CloudStack
> Eucalyptus (EMI)
> Flexiant
> Google Compute Engine
> Microsoft Azure
> Nimbula
> OpenStack
> VMware VCD
> Abiquo
> AWS (EC2)
> CloudStack
> Eucalyptus (EMI)
> Flexiant
> Google Compute Engine
> Microsoft Azure
> Nimbula
> OpenStack
> VMware VCD
PhysicalPhysical VirtualVirtual CloudCloud ContainerContainer> Docker
> LXC
> Docker
> LXC
![Page 17: Hammr Project Update: Machine Images and Docker Containers for your Cloud, OW2con'16, Paris.](https://reader031.fdocuments.in/reader031/viewer/2022022410/58e56c811a28abd82b8b580b/html5/thumbnails/17.jpg)
1717
© Copyright 2016 UShareSoft© Copyright 2016 UShareSoft
Docker Integration
![Page 18: Hammr Project Update: Machine Images and Docker Containers for your Cloud, OW2con'16, Paris.](https://reader031.fdocuments.in/reader031/viewer/2022022410/58e56c811a28abd82b8b580b/html5/thumbnails/18.jpg)
1818
© Copyright 2016 UShareSoft© Copyright 2016 UShareSoft
Hammr: Docker Image Support
Self-contained Docker Base Image
(1 Docker image by hammr file)
Self-contained Docker Base Image
(1 Docker image by hammr file)
BenefitsBenefits
Software governance for Docker Images
Consistency between VM ↔ Docker Images
Software governance for Docker Images
Consistency between VM ↔ Docker Images
> Full software governance: keep control over all software packagesand versions within your image
> Transparency: see at a glance which OS packages and software filesmake up your image
> Repeatability: generate a consistent Docker image each and everytime
> Full software governance: keep control over all software packagesand versions within your image
> Transparency: see at a glance which OS packages and software filesmake up your image
> Repeatability: generate a consistent Docker image each and everytime
![Page 19: Hammr Project Update: Machine Images and Docker Containers for your Cloud, OW2con'16, Paris.](https://reader031.fdocuments.in/reader031/viewer/2022022410/58e56c811a28abd82b8b580b/html5/thumbnails/19.jpg)
1919
© Copyright 2016 UShareSoft© Copyright 2016 UShareSoft
Latest News andOutlook
![Page 20: Hammr Project Update: Machine Images and Docker Containers for your Cloud, OW2con'16, Paris.](https://reader031.fdocuments.in/reader031/viewer/2022022410/58e56c811a28abd82b8b580b/html5/thumbnails/20.jpg)
2020
© Copyright 2016 UShareSoft© Copyright 2016 UShareSoft
Hammr: Latest Features
BenefitsBenefits
Software governance for Docker Images
Consistency between VM ↔ Docker Images
Software governance for Docker Images
Consistency between VM ↔ Docker Images
> YAML support> Facility to define a software bundle from a directory> Compatibility with UForge AppCenter 3.6> Support of Outscale cloud format> Hammr documentation moved to Read the Docs
> Documentation source on Github
> YAML support> Facility to define a software bundle from a directory> Compatibility with UForge AppCenter 3.6> Support of Outscale cloud format> Hammr documentation moved to Read the Docs
> Documentation source on Github
![Page 21: Hammr Project Update: Machine Images and Docker Containers for your Cloud, OW2con'16, Paris.](https://reader031.fdocuments.in/reader031/viewer/2022022410/58e56c811a28abd82b8b580b/html5/thumbnails/21.jpg)
2121
© Copyright 2016 UShareSoft© Copyright 2016 UShareSoft
Hammr: Outlook
BenefitsBenefits
Software governance for Docker Images
Consistency between VM ↔ Docker Images
Software governance for Docker Images
Consistency between VM ↔ Docker Images
> Improve workload migration automation> Authentication modes on source workloads
> Support of Docker layers> Model layers> Assemble a stack from layers
> Bundles enhancement> Add configuration scripts and OS packages to bundles
> Ability to execute scripts at template build time
> Improve workload migration automation> Authentication modes on source workloads
> Support of Docker layers> Model layers> Assemble a stack from layers
> Bundles enhancement> Add configuration scripts and OS packages to bundles
> Ability to execute scripts at template build time
![Page 22: Hammr Project Update: Machine Images and Docker Containers for your Cloud, OW2con'16, Paris.](https://reader031.fdocuments.in/reader031/viewer/2022022410/58e56c811a28abd82b8b580b/html5/thumbnails/22.jpg)
2222
© Copyright 2016 UShareSoft© Copyright 2016 UShareSoft
Machine image & container builderfor the cloud
It's an open source OW2 project
Use it! Contributions welcome!
hammr.ioow2.org/ActivitiesDashboard/hammrhttps://github.com/usharesoft/hammr
![Page 23: Hammr Project Update: Machine Images and Docker Containers for your Cloud, OW2con'16, Paris.](https://reader031.fdocuments.in/reader031/viewer/2022022410/58e56c811a28abd82b8b580b/html5/thumbnails/23.jpg)
Copyright © UShareSoft 2016 Copyright © UShareSoft 2016
Joris Bremond, Alexandre [email protected]
www.usharesoft.com@usharesoft