IBM Bluemix
Digital Innovation Platform
Daniela Zuppini
Senior IT Specialist
IBM Business Partner Solution Hub
Global Business Partners, IBM Italy
Inspiring Innovation
What is Bluemix?What is Bluemix?
05/09/17 2
Today’s apps must keep up with the speed of the revolution.
Core
IT
Benefits
Fully customizable.
Few limitations.
Necessary for some solutions.
Existing Investments.
Time Commitment
Weeks to setup and deploy.
Maintenance/upgrades of
hardware and software.
~ Weeks ~ Days
Code
Data
Runtime
Middleware
OS
Virtualization
Servers
Storage
Networking
~ Minutes
Time to initial deployment
Customer Managed
05/09/17 3
Today’s apps must keep up with the speed of the revolution.
~ Minutes
Platform
as a ServiceCustomer Managed
Service Provider Managed
IaaS
Benefits
Setup environments and
deploy apps very quickly.
Infrastructureand platform
managed by SP.
Time Commitment
Minutes to setup and deploy.
Focus on your apps and their
data.
~ Weeks
IBM Bluemix
~ Days
Time to initial deployment
Code
Data
Runtime
Middleware
OS
Virtualization
Servers
Storage
Networking
Core IT
05/09/17 4
IBM Bluemix is a
Cloud Foundry
Certified Platforms
https://www.cloudfoundry.org/certified-platforms/
05/09/17 5
Bluemix is a Container Technology
- Containers, in general, are common technology
- They come in various implementations:
- Docker
- Garden
- ...
- They come with various orchestrators:
- Docker Swarm
- Kubernetes
- Diego
- CF Diego is one path to containers
05/09/17 6
Container History
chroot
1979
A chroot on Unix operating systems is an
operation that changes the apparent root
directory for the current running process
and its children. A program that is run in
such a modified environment cannot name
(and therefore normally cannot access) files
outside the designated directory tree. … The
modified environment is called a "chroot
jail".
https://en.wikipedia.org/wiki/ChrootChr
cgroups
2007
LXC
2008
warden
2011
2012
rocket
2016
Docker,
lmctfy
2014
Garden,
runCLXC (Linux Containers) is an operating-
system-level virtualization environment for
running multiple isolated Linux systems
(containers) on a single Linux control host.
…
LXC combines kernel's cgroups and
support for isolated namespaces to
provide an isolated environment for
applications.
https://en.wikipedia.org/wiki/LXC
05/09/17 7
Cloud Foundry BOSH
METRICS
& LOGGING
MESSAGING
SERVICES
APP STORAGE
& EXECUTION
APP LIFECYCLE
AUTHENTICATION
ROUTINGRouter
OAuth2 Server (UAA) Login Server
Metrics Collector App Log Aggregator
BBS (HTTP/S) NATS Message BusConsul
Service Brokers
Cloud Controller Diego Brainnsync Cell Reps
App Execution (Diego Cell)
Garden
Blob
Store
Buildpacks
IBM Liberty
IBM Node-JS
Java
Ruby
Node-JS
Go
Python
PHP
ASP.NET
XPages
Micro
Clouds
Private
Clouds
Public
Clouds
Bluemix Cloud Foundry Architecture
05/09/17 8
CLI tool to interact with
Cloud Foundry
Cloud Foundry Command Line Interface tool is the way to interact
with Cloud Foundry.
It’s used to :
•Login to CF
•Deploy application from your Workstation to cloud
•Scale memory for your application
•Scale instances of your application
•Create space to organize environment
•And many other usage...
cf help –a to see all possible command cf CLI can run
05/09/17 9
CLI tool installation
http://docs.cloudfoundry.org/cf-cli/install-go-cli.html
Follow the instructions for your Operating System:
You can get instruction from Bluemix when you provision the runtime environment
From Getting Started panel inside the runtime instance:
https://github.com/cloudfoundry/cli#downloads
To verify that cf CLI is correctly installed:
cf --version
CLI is available for all Operating System except Android and iOS
05/09/17 10
Cloud Foundry
PaaS Handles Configuration and Deployment
a. Upload app
bits and
metadata
push app
Router
b. Create and bind services
c. Stage application
d. Deploy application
Cloud Foundry
Runtime
(PaaS)
Cloud ControllerCloud Controller
BuildpackBuildpack
CellCell
+ app MD
DiegoDiego
Garden
CellCell
Garden
CellCell
Garden
05/09/17 11
cf login
The first step to be performed
is the :
cf login
API endpoint Region
https://api.ng.bluemix.net US South
https://api.eu-gb.bluemix.net United Kingdom
https://api.au-syd.bluemix.net Sydney
Login tells CF which is:
i.your Cloud Foundry provider
ii.your organization
iii.your space
05/09/17 12
Space and Organization
Space contains application and services.
Organization groups all spaces together. Organization has
administrative task.
User account consists of username and password:
username are usually email.
Quotas are size constraints for organization and spaces.
used to control cost.
05/09/17 13
Code deployment process
A process made of 3 stages:
BUILD Transforms source code into an executable
RELEASE Combines the executable with the available configuration
RUN Release package is deployed and executed
05/09/17 14
What happens with cf push
• cf CLI sends all our files to Cloud Controller
• Cloud Controller finds the right Buildpack
• Files are processed by Buildpack
• Buildpack builds the droplet
• Cloud Foundry stores all files into a Blob store
Manifest.yml
Used to specify parameters necessary to build the application
Manifest guarantees droplet is produced always in the same way
Buildpack functionality :
• detect the programming language of the application
• install dependencies required by the application
• compile the application if necessary
• provide to Cloud Foundry the application configuration data
In detection step, Buildpack looks for particular file or directories
Es. Node.js buildpack looks for file package.json
Build + Release stage
05/09/17 15
Buildpack in execution
05/09/17 16
Last stage is Run
BUILD and RELEASE complete successfully
Cloud Foundry RUNs your application
When your application is running
Cloud Foundry ensure your application is healthy
Cloud Foundry health monitor constantly checks your application status
• automatically replace crashed container
• email alert for unexpected behaviour
05/09/17 17
Logging
Logaggregator
Logaggregator is responsible to manage logging
Logs flow continuosly as long as the application is running
Your application writes to STDERR and STDOUT
A log line contains:
Timestamp: determined by logaggregator when receives data
Log Type: represent origin of log. It’s a 3 letter code: API , STG, RTR, LGR, APP,CELL
API=user api call
APP=application that emits log
CELL= cell logs when it start/stop the app.....
Channel: STDOUT, STDERR
Message: text with log
05/09/17 18
Diego
Diego is the hearth of Cloud Foundry architecture.
Applications run in Garden containers inside Diego Cell.
Diego orchestrates application execution and determines in which
Diego cell deploy your application.
Application are divided in two categories:
Single task :
application that is discarded as soon as the task is completed
Long running task:
like web application and worker app
05/09/17 19
Cloud Foundry Services
Cloud Foundry services are available on catalog
cf marketplace to view all services available in the catalog
When a new service is provisioned:
Service Broker
takes the request
creates the service instance
when the new service is online, binds service instance to the application
05/09/17 20
05/09/17 21
https://www.ibm.com/devops/method/tutorials/tutorial_toolchain_microservices
Bluemix Toolchain
05/09/17 22
THANK YOU

IBM Bluemix cloudfoundry platform

  • 1.
    IBM Bluemix Digital InnovationPlatform Daniela Zuppini Senior IT Specialist IBM Business Partner Solution Hub Global Business Partners, IBM Italy
  • 2.
    Inspiring Innovation What isBluemix?What is Bluemix? 05/09/17 2
  • 3.
    Today’s apps mustkeep up with the speed of the revolution. Core IT Benefits Fully customizable. Few limitations. Necessary for some solutions. Existing Investments. Time Commitment Weeks to setup and deploy. Maintenance/upgrades of hardware and software. ~ Weeks ~ Days Code Data Runtime Middleware OS Virtualization Servers Storage Networking ~ Minutes Time to initial deployment Customer Managed 05/09/17 3
  • 4.
    Today’s apps mustkeep up with the speed of the revolution. ~ Minutes Platform as a ServiceCustomer Managed Service Provider Managed IaaS Benefits Setup environments and deploy apps very quickly. Infrastructureand platform managed by SP. Time Commitment Minutes to setup and deploy. Focus on your apps and their data. ~ Weeks IBM Bluemix ~ Days Time to initial deployment Code Data Runtime Middleware OS Virtualization Servers Storage Networking Core IT 05/09/17 4
  • 5.
    IBM Bluemix isa Cloud Foundry Certified Platforms https://www.cloudfoundry.org/certified-platforms/ 05/09/17 5
  • 6.
    Bluemix is aContainer Technology - Containers, in general, are common technology - They come in various implementations: - Docker - Garden - ... - They come with various orchestrators: - Docker Swarm - Kubernetes - Diego - CF Diego is one path to containers 05/09/17 6
  • 7.
    Container History chroot 1979 A chrooton Unix operating systems is an operation that changes the apparent root directory for the current running process and its children. A program that is run in such a modified environment cannot name (and therefore normally cannot access) files outside the designated directory tree. … The modified environment is called a "chroot jail". https://en.wikipedia.org/wiki/ChrootChr cgroups 2007 LXC 2008 warden 2011 2012 rocket 2016 Docker, lmctfy 2014 Garden, runCLXC (Linux Containers) is an operating- system-level virtualization environment for running multiple isolated Linux systems (containers) on a single Linux control host. … LXC combines kernel's cgroups and support for isolated namespaces to provide an isolated environment for applications. https://en.wikipedia.org/wiki/LXC 05/09/17 7
  • 8.
    Cloud Foundry BOSH METRICS &LOGGING MESSAGING SERVICES APP STORAGE & EXECUTION APP LIFECYCLE AUTHENTICATION ROUTINGRouter OAuth2 Server (UAA) Login Server Metrics Collector App Log Aggregator BBS (HTTP/S) NATS Message BusConsul Service Brokers Cloud Controller Diego Brainnsync Cell Reps App Execution (Diego Cell) Garden Blob Store Buildpacks IBM Liberty IBM Node-JS Java Ruby Node-JS Go Python PHP ASP.NET XPages Micro Clouds Private Clouds Public Clouds Bluemix Cloud Foundry Architecture 05/09/17 8
  • 9.
    CLI tool tointeract with Cloud Foundry Cloud Foundry Command Line Interface tool is the way to interact with Cloud Foundry. It’s used to : •Login to CF •Deploy application from your Workstation to cloud •Scale memory for your application •Scale instances of your application •Create space to organize environment •And many other usage... cf help –a to see all possible command cf CLI can run 05/09/17 9
  • 10.
    CLI tool installation http://docs.cloudfoundry.org/cf-cli/install-go-cli.html Followthe instructions for your Operating System: You can get instruction from Bluemix when you provision the runtime environment From Getting Started panel inside the runtime instance: https://github.com/cloudfoundry/cli#downloads To verify that cf CLI is correctly installed: cf --version CLI is available for all Operating System except Android and iOS 05/09/17 10
  • 11.
    Cloud Foundry PaaS HandlesConfiguration and Deployment a. Upload app bits and metadata push app Router b. Create and bind services c. Stage application d. Deploy application Cloud Foundry Runtime (PaaS) Cloud ControllerCloud Controller BuildpackBuildpack CellCell + app MD DiegoDiego Garden CellCell Garden CellCell Garden 05/09/17 11
  • 12.
    cf login The firststep to be performed is the : cf login API endpoint Region https://api.ng.bluemix.net US South https://api.eu-gb.bluemix.net United Kingdom https://api.au-syd.bluemix.net Sydney Login tells CF which is: i.your Cloud Foundry provider ii.your organization iii.your space 05/09/17 12
  • 13.
    Space and Organization Spacecontains application and services. Organization groups all spaces together. Organization has administrative task. User account consists of username and password: username are usually email. Quotas are size constraints for organization and spaces. used to control cost. 05/09/17 13
  • 14.
    Code deployment process Aprocess made of 3 stages: BUILD Transforms source code into an executable RELEASE Combines the executable with the available configuration RUN Release package is deployed and executed 05/09/17 14
  • 15.
    What happens withcf push • cf CLI sends all our files to Cloud Controller • Cloud Controller finds the right Buildpack • Files are processed by Buildpack • Buildpack builds the droplet • Cloud Foundry stores all files into a Blob store Manifest.yml Used to specify parameters necessary to build the application Manifest guarantees droplet is produced always in the same way Buildpack functionality : • detect the programming language of the application • install dependencies required by the application • compile the application if necessary • provide to Cloud Foundry the application configuration data In detection step, Buildpack looks for particular file or directories Es. Node.js buildpack looks for file package.json Build + Release stage 05/09/17 15
  • 16.
  • 17.
    Last stage isRun BUILD and RELEASE complete successfully Cloud Foundry RUNs your application When your application is running Cloud Foundry ensure your application is healthy Cloud Foundry health monitor constantly checks your application status • automatically replace crashed container • email alert for unexpected behaviour 05/09/17 17
  • 18.
    Logging Logaggregator Logaggregator is responsibleto manage logging Logs flow continuosly as long as the application is running Your application writes to STDERR and STDOUT A log line contains: Timestamp: determined by logaggregator when receives data Log Type: represent origin of log. It’s a 3 letter code: API , STG, RTR, LGR, APP,CELL API=user api call APP=application that emits log CELL= cell logs when it start/stop the app..... Channel: STDOUT, STDERR Message: text with log 05/09/17 18
  • 19.
    Diego Diego is thehearth of Cloud Foundry architecture. Applications run in Garden containers inside Diego Cell. Diego orchestrates application execution and determines in which Diego cell deploy your application. Application are divided in two categories: Single task : application that is discarded as soon as the task is completed Long running task: like web application and worker app 05/09/17 19
  • 20.
    Cloud Foundry Services CloudFoundry services are available on catalog cf marketplace to view all services available in the catalog When a new service is provisioned: Service Broker takes the request creates the service instance when the new service is online, binds service instance to the application 05/09/17 20
  • 21.
  • 22.