29
CI/CD on Windows-based Environments Your Social Investment Network eToro©2015 Presentation materials are confidential and should not be copied, distributed or passed on, directly or indirectly, to any other person. Noam Shochat, Sr. DevOps Engineer | [email protected]

CI/CD on Windows-Based Environments - Noam Shochat, eToro - DevOpsDays Tel Aviv 2015

Embed Size (px)

Citation preview

Page 1: CI/CD on Windows-Based Environments - Noam Shochat, eToro - DevOpsDays Tel Aviv 2015

CI/CD on Windows-based Environments

Your Social Investment Network

eToro©2015 Presentation materials are confidential and should not be copied, distributed or

passed on, directly or indirectly, to any other person.

Noam Shochat, Sr. DevOps Engineer | [email protected]

Page 2: CI/CD on Windows-Based Environments - Noam Shochat, eToro - DevOpsDays Tel Aviv 2015

● The world’s largest social investment network

● Founded in 2007, raised $60M

● >200 employees (~half in Engineering)

● Offices in IL, UK, CY, RU and expending

Some Basic Facts...

eToro©2015 Presentation materials are confidential and should not be copied, distributed or passed on, directly or

indirectly, to any other person.

Page 3: CI/CD on Windows-Based Environments - Noam Shochat, eToro - DevOpsDays Tel Aviv 2015

5M registered users. 140 Countries. 150M Trades.

Page 4: CI/CD on Windows-Based Environments - Noam Shochat, eToro - DevOpsDays Tel Aviv 2015

9 different Apps!

Page 5: CI/CD on Windows-Based Environments - Noam Shochat, eToro - DevOpsDays Tel Aviv 2015

eToro’s Legacy Technology

● HTML/ASP, Flash, iOS & Android clients

● 2 Geo-distributed data centers

● >130 Services

● > 500 Servers

● Hybrid MS tech stack & Open Source Server technologies

(Redis, RabbitMQ, HAProxy, etc…)

● SQL Server 2014 EE

eToro©2015 Presentation materials are confidential and should not be copied, distributed or passed on, directly or

indirectly, to any other person.

Page 6: CI/CD on Windows-Based Environments - Noam Shochat, eToro - DevOpsDays Tel Aviv 2015

CI / CD ingredient

CI / CD

Code commit

Deploy and tests in QA

Production Build, Unit tests

Page 7: CI/CD on Windows-Based Environments - Noam Shochat, eToro - DevOpsDays Tel Aviv 2015

Different OS’s

5 different

environments

Different development

languages

Page 8: CI/CD on Windows-Based Environments - Noam Shochat, eToro - DevOpsDays Tel Aviv 2015
Page 9: CI/CD on Windows-Based Environments - Noam Shochat, eToro - DevOpsDays Tel Aviv 2015

Manage all with Jenkins

Page 10: CI/CD on Windows-Based Environments - Noam Shochat, eToro - DevOpsDays Tel Aviv 2015

CI / CD Pipeline

Check-In

GitHub

Mercurial

Build

MSBuild

Unit tests

NUnit

Integratio

n tests

UI Testing

Prod

Deployment

Managed by Jenkins

QA

Deployment

Page 11: CI/CD on Windows-Based Environments - Noam Shochat, eToro - DevOpsDays Tel Aviv 2015

Jenkins Cross Platform Orchestration

Jenkins master

Page 12: CI/CD on Windows-Based Environments - Noam Shochat, eToro - DevOpsDays Tel Aviv 2015

Build your flow with Jenkins

● Build Flow plugin

● WorkFlow plugin

Page 13: CI/CD on Windows-Based Environments - Noam Shochat, eToro - DevOpsDays Tel Aviv 2015

Inside Jenkins Job

Script languages:

● Batch

● Powershell

● Shell

● Ruby

Page 14: CI/CD on Windows-Based Environments - Noam Shochat, eToro - DevOpsDays Tel Aviv 2015

Auditing and reporting

● Graphite

● Splunk

● Slack

Page 15: CI/CD on Windows-Based Environments - Noam Shochat, eToro - DevOpsDays Tel Aviv 2015

Provisioning servers and Deploy with Puppet

Page 16: CI/CD on Windows-Based Environments - Noam Shochat, eToro - DevOpsDays Tel Aviv 2015

Things we’re doing with puppet

define general::web_service(

$artifact_source,

$config_file_name='web.config',

$configerb_path,

$erb_config_file_name='web.config.erb',

$deploy_destination,

$zipfile_mount_name,

$port=80,

$enableanonymousauthentication=false,

$template_config={}

)

{

include general::7zip

include general::remotesign

include general::basicfoldersinstall

addwebsite {"${name}":

port => $port,

require => Class['enableiis']

}

addwebsite::enablewindowsauthentication{"${name}":

site_name => $name,

require => [Class['enableiis'],Addwebsite["${name}"]],

}

addwebsite::enableanonymousauthentication{"${name}":

site_name => $name,

enable => $enableanonymousauthentication,

require => [Class['enableiis'],Addwebsite["${name}"]],

}

● Enable features

● Install 3rd party apps

● Creating folders

● Installing / Configure win

services

● Installing / Configure

websites (IIS)

Page 17: CI/CD on Windows-Based Environments - Noam Shochat, eToro - DevOpsDays Tel Aviv 2015

Orchestration with mcollective

Page 18: CI/CD on Windows-Based Environments - Noam Shochat, eToro - DevOpsDays Tel Aviv 2015

Mcollective architecture

Mcollective

Client

RabbitMQServer

Servers

Page 19: CI/CD on Windows-Based Environments - Noam Shochat, eToro - DevOpsDays Tel Aviv 2015

Trigger Mcollective

Page 20: CI/CD on Windows-Based Environments - Noam Shochat, eToro - DevOpsDays Tel Aviv 2015

Tools for Key Value store

Page 21: CI/CD on Windows-Based Environments - Noam Shochat, eToro - DevOpsDays Tel Aviv 2015

Hiera

● Developed by Puppet labs, there for fully integrated with

puppet

● Key value store

● Configuration file per environment on the same puppet

master

Page 22: CI/CD on Windows-Based Environments - Noam Shochat, eToro - DevOpsDays Tel Aviv 2015

ETCD

acl to the office acl to the office

Azure North Europe

server 1 server 2

APP1

DLL

APP2

DLL

APP3

DLL

CCM 2

UI -

Admin

server 3 server 4

CCM 4

Azure West Europe

ILB LBS ILB LBS

CCM 3CCM 1

Page 23: CI/CD on Windows-Based Environments - Noam Shochat, eToro - DevOpsDays Tel Aviv 2015

CI / CD on Azure

Cloud

Page 24: CI/CD on Windows-Based Environments - Noam Shochat, eToro - DevOpsDays Tel Aviv 2015

PAAS in Azure

● Cloud service

● Slots

● Uploading Packages

● Integration with github

(Git Hook)

Page 25: CI/CD on Windows-Based Environments - Noam Shochat, eToro - DevOpsDays Tel Aviv 2015

IAAS on Azure

● Jenkins agent

● Puppet master

● Mcollective client

● Mcollective server and puppet agent on all servers.

Page 26: CI/CD on Windows-Based Environments - Noam Shochat, eToro - DevOpsDays Tel Aviv 2015

Summaries

● Jenkins - Main CI / CD tool

● Puppet - Provisioning and deployment

● Mcollective - Orchestrate

● PowerShell Azure SDK - For deploying Web/worker

roles

● This is all just tools - DevOps is a lot more

Page 27: CI/CD on Windows-Based Environments - Noam Shochat, eToro - DevOpsDays Tel Aviv 2015

Wish List

● Automate the creation of new Jobs and Flows in

Jenkins.

● More self service

Page 28: CI/CD on Windows-Based Environments - Noam Shochat, eToro - DevOpsDays Tel Aviv 2015
Page 29: CI/CD on Windows-Based Environments - Noam Shochat, eToro - DevOpsDays Tel Aviv 2015

Noam Shochat, Sr. DevOps Engineer | [email protected]