SlideShare a Scribd company logo
Application/Web
Server
Sapna Solutions
1
       Simple Rails Setup

    One Rails instance handles all requests Rails is
     single-threaded: There is only one concurrent
     request




Sapna Solutions
2

       Rails Setup




Sapna Solutions
3
      Typical Rails Setup
     A load-balancer distributes the incoming
      requests

     Some load-balancers will deliver static requests
      themselves

     Several Rails instances handle all requests

     Number of concurrent requests equals number of
      Rails instances




Sapna Solutions
4
      Deployment Questions




Sapna Solutions
5
      Deployment Questions




Sapna Solutions
6

   SERVERS
  Rails Application Server     Proxy/Web Server



    FastCGI                     Apache2

    Mongrel                     Nginx

    mod_rails / Phussion        Lighttpd
     Passenger
                                 HA-Proxy
    JRuby + Glassfish & Co.




Sapna Solutions
FastCGI                                           7




    Protocol to communicate with long-running CGI
     applications

    Usage of either mod_fcgi with Apache 1.3 or
     mod_fcgi with Lighttpd

    Proxy local and remote FastCGI instances

    Oldest way of deploying Rails

    Deprecated and unstable

    Hard to debug (FastCGI protocol)



Sapna Solutions
FastCGI   8




Sapna Solutions
9




Sapna Solutions
10




                  Mongrel




Sapna Solutions
11
   Mongrel

    Developed by Zed Shaw as an alternative to
     FastCGI
    Complete HTTP-Server that can load arbitrary
     Ruby-servlets
    Built-in Rails support




Sapna Solutions
12
          Mongrel




Sapna Solutions
13
          Mongrel




Sapna Solutions
14

   Mongrel
    Very robust

    Strict HTTP parser

    Easy to debug (HTTP!)

    Used to be defacto deployment setup with
     Apache 2.2 and mod_proxy_balancer

    Can be a bit difficult to setup (mongrel_cluster,
     ports, Apache)

    Not so easy on mass/virtual hosting



Sapna Solutions
15




     Mod_rails a.k.a Phusion Passenger




Sapna Solutions
Mod_rails a.k.a Phusion                              16

   Passenger
    Module for Apache 2.2 (and Nginx)

    Allows Apache to control Rails instances

    Apache starts and stops application instances
     depending on the application load

    Able to run any Rack-compatible Ruby application
     (Merb, Sinatra & Co.)

    Only manages Rails on one host - no remote
     instances

    Combine with HTTP-Proxy / balancing solution



Sapna Solutions
17
   Install Phusion Passenger
    Install Apache module




    Load and activate in Apache




Sapna Solutions
18
   Customized Phusion Passenger




Sapna Solutions
19
   Control Phusion Passenger


       Restart after deployment:




Sapna Solutions
20
   Phusion Passenger




Sapna Solutions
21
   Phusion Passenger




Sapna Solutions
22

   Phusion Passenger
    Ready for production

    Makes setup easier – on the single machine level

    Multiple servers still require load balancer

    Suitable for mass-hosting

    upcoming standard way of deploying Rails




Sapna Solutions
23

   Apache 2.2
    Apache 2.2 introduced mod_proxy_balancer

    mod_proxy_balancer can speak to multiple
     backends and balance requests

    Apache can acts as a pure proxy or can also
     serve static files




Sapna Solutions
24




                  Setups
                  Recommended
Sapna Solutions
25
   Small Site




Sapna Solutions
26
   Medium Site




Sapna Solutions
27




Sapna Solutions
Heavy Static Files   28




Sapna Solutions
29




Sapna Solutions
30
           Application Server Handler




Sapna Solutions
31
           RACK




Sapna Solutions
32
           Rack Handler




Sapna Solutions
33
           Rack Supports




Sapna Solutions
34
         What are we using?
         Speedy Rails (vps213 and vps214) (Canada)

         Apache2

         Ruby Enterprise(1.8)

         Phusion Passenger

         MySql

         Build, Staging and Production Environments

         Every RAILS APP log maintained




Sapna Solutions
Where our applications reside?        35




                   Login to VPS 214



                   Sudo su - deploy




                  cd /var/www/apps/




Sapna Solutions
36
How to debug?

                       Host <domainname>



                   Checkout ip address serving it




                  APACHE CONF file (path to app)




Sapna Solutions
37




                  DEPLOYMENT




Sapna Solutions
38




Sapna Solutions
39



   We prefer




Sapna Solutions
40
How to DEPLOY?

                       CAPISTRANO



                      CUSTOM TASKS




                  EASIEST AND TRUSTED WAY




Sapna Solutions
41
CAPISTRANO Requirements




Sapna Solutions
42
What does Capistrano do?




Sapna Solutions
43
Capistrano Deployment Cycle




Sapna Solutions
44




Sapna Solutions

More Related Content

What's hot

Comandos
ComandosComandos
Comandos1 2d
 
Enabling Active Networks Services on A Gigabit Routing Switch
Enabling Active Networks Services on A Gigabit Routing SwitchEnabling Active Networks Services on A Gigabit Routing Switch
Enabling Active Networks Services on A Gigabit Routing Switch
Tal Lavian Ph.D.
 
Ccna rse chp9 nat fo i_pv4
Ccna rse chp9 nat fo i_pv4Ccna rse chp9 nat fo i_pv4
Ccna rse chp9 nat fo i_pv4
newbie2019
 
EMEA Airheads- ArubaOS - High availability with AP Fast Failover
EMEA Airheads- ArubaOS - High availability with AP Fast FailoverEMEA Airheads- ArubaOS - High availability with AP Fast Failover
EMEA Airheads- ArubaOS - High availability with AP Fast Failover
Aruba, a Hewlett Packard Enterprise company
 
Exos concepts guide_15_4
Exos concepts guide_15_4Exos concepts guide_15_4
Exos concepts guide_15_4
alexandr martynjuk
 
Automating SAP HANA System Replication
Automating SAP HANA System ReplicationAutomating SAP HANA System Replication
Automating SAP HANA System Replication
Dirk Oppenkowski
 
Ccna rse dynamic routing
Ccna rse dynamic routingCcna rse dynamic routing
Ccna rse dynamic routing
newbie2019
 
Cumulus Linux 2.5.3
Cumulus Linux 2.5.3Cumulus Linux 2.5.3
Cumulus Linux 2.5.3
Cumulus Networks
 
7 network programmability concepts python-ansible
7 network programmability concepts python-ansible7 network programmability concepts python-ansible
7 network programmability concepts python-ansible
SagarR24
 
Keynote: Idiomatic RabbitMQ - Gavin M Roy
Keynote: Idiomatic RabbitMQ - Gavin M RoyKeynote: Idiomatic RabbitMQ - Gavin M Roy
Keynote: Idiomatic RabbitMQ - Gavin M Roy
RabbitMQ Summit
 
Inter-VLAN Routing
Inter-VLAN RoutingInter-VLAN Routing
Inter-VLAN Routingrmosate
 
ONAP Overview Webinar - Aarna Networks & Cloudify
ONAP Overview Webinar - Aarna Networks & CloudifyONAP Overview Webinar - Aarna Networks & Cloudify
ONAP Overview Webinar - Aarna Networks & Cloudify
Cloudify Community
 
Automate SAP HANA System Replication with Veritas InfoScale Availability
Automate SAP HANA System Replication with Veritas InfoScale AvailabilityAutomate SAP HANA System Replication with Veritas InfoScale Availability
Automate SAP HANA System Replication with Veritas InfoScale Availability
Eugenio Mendoza
 
EVPN Introduction
EVPN IntroductionEVPN Introduction
10 gb ethernet
10 gb ethernet10 gb ethernet
10 gb ethernet
ronpoul
 
Cap6 intervlan routing
Cap6   intervlan routingCap6   intervlan routing
Cap6 intervlan routing
Hector Camba Lainez
 
Ccna Quick Notes –VLANs
Ccna Quick Notes –VLANsCcna Quick Notes –VLANs
Ccna Quick Notes –VLANs
CCNAResources
 
Audio video ethernet (avb cobra net dante)
Audio video ethernet (avb cobra net dante)Audio video ethernet (avb cobra net dante)
Audio video ethernet (avb cobra net dante)
Jeff Green
 
Kendel Avaya-Fabric connect - Demo Lab Guide – L3VSN & Multicast-8
Kendel Avaya-Fabric connect - Demo Lab Guide – L3VSN &  Multicast-8Kendel Avaya-Fabric connect - Demo Lab Guide – L3VSN &  Multicast-8
Kendel Avaya-Fabric connect - Demo Lab Guide – L3VSN & Multicast-8
ELI KENDEL אלי קנדל
 

What's hot (20)

Comandos
ComandosComandos
Comandos
 
Enabling Active Networks Services on A Gigabit Routing Switch
Enabling Active Networks Services on A Gigabit Routing SwitchEnabling Active Networks Services on A Gigabit Routing Switch
Enabling Active Networks Services on A Gigabit Routing Switch
 
Ccna rse chp9 nat fo i_pv4
Ccna rse chp9 nat fo i_pv4Ccna rse chp9 nat fo i_pv4
Ccna rse chp9 nat fo i_pv4
 
EMEA Airheads- ArubaOS - High availability with AP Fast Failover
EMEA Airheads- ArubaOS - High availability with AP Fast FailoverEMEA Airheads- ArubaOS - High availability with AP Fast Failover
EMEA Airheads- ArubaOS - High availability with AP Fast Failover
 
Exos concepts guide_15_4
Exos concepts guide_15_4Exos concepts guide_15_4
Exos concepts guide_15_4
 
Automating SAP HANA System Replication
Automating SAP HANA System ReplicationAutomating SAP HANA System Replication
Automating SAP HANA System Replication
 
Ccna rse dynamic routing
Ccna rse dynamic routingCcna rse dynamic routing
Ccna rse dynamic routing
 
Cumulus Linux 2.5.3
Cumulus Linux 2.5.3Cumulus Linux 2.5.3
Cumulus Linux 2.5.3
 
7 network programmability concepts python-ansible
7 network programmability concepts python-ansible7 network programmability concepts python-ansible
7 network programmability concepts python-ansible
 
Mecanismos de transicion pv6
Mecanismos de transicion pv6Mecanismos de transicion pv6
Mecanismos de transicion pv6
 
Keynote: Idiomatic RabbitMQ - Gavin M Roy
Keynote: Idiomatic RabbitMQ - Gavin M RoyKeynote: Idiomatic RabbitMQ - Gavin M Roy
Keynote: Idiomatic RabbitMQ - Gavin M Roy
 
Inter-VLAN Routing
Inter-VLAN RoutingInter-VLAN Routing
Inter-VLAN Routing
 
ONAP Overview Webinar - Aarna Networks & Cloudify
ONAP Overview Webinar - Aarna Networks & CloudifyONAP Overview Webinar - Aarna Networks & Cloudify
ONAP Overview Webinar - Aarna Networks & Cloudify
 
Automate SAP HANA System Replication with Veritas InfoScale Availability
Automate SAP HANA System Replication with Veritas InfoScale AvailabilityAutomate SAP HANA System Replication with Veritas InfoScale Availability
Automate SAP HANA System Replication with Veritas InfoScale Availability
 
EVPN Introduction
EVPN IntroductionEVPN Introduction
EVPN Introduction
 
10 gb ethernet
10 gb ethernet10 gb ethernet
10 gb ethernet
 
Cap6 intervlan routing
Cap6   intervlan routingCap6   intervlan routing
Cap6 intervlan routing
 
Ccna Quick Notes –VLANs
Ccna Quick Notes –VLANsCcna Quick Notes –VLANs
Ccna Quick Notes –VLANs
 
Audio video ethernet (avb cobra net dante)
Audio video ethernet (avb cobra net dante)Audio video ethernet (avb cobra net dante)
Audio video ethernet (avb cobra net dante)
 
Kendel Avaya-Fabric connect - Demo Lab Guide – L3VSN & Multicast-8
Kendel Avaya-Fabric connect - Demo Lab Guide – L3VSN &  Multicast-8Kendel Avaya-Fabric connect - Demo Lab Guide – L3VSN &  Multicast-8
Kendel Avaya-Fabric connect - Demo Lab Guide – L3VSN & Multicast-8
 

Viewers also liked

HTTP web server 구현
HTTP web server 구현HTTP web server 구현
HTTP web server 구현
Javajigi Jaesung
 
소프트웨어 학습 및 자바 웹 개발자 학습 로드맵
소프트웨어 학습 및 자바 웹 개발자 학습 로드맵소프트웨어 학습 및 자바 웹 개발자 학습 로드맵
소프트웨어 학습 및 자바 웹 개발자 학습 로드맵
Javajigi Jaesung
 
[오픈소스컨설팅]JBoss 5 Detail
[오픈소스컨설팅]JBoss 5 Detail[오픈소스컨설팅]JBoss 5 Detail
[오픈소스컨설팅]JBoss 5 Detail
Ji-Woong Choi
 
[오픈소스컨설팅]J boss6 7_교육자료
[오픈소스컨설팅]J boss6 7_교육자료[오픈소스컨설팅]J boss6 7_교육자료
[오픈소스컨설팅]J boss6 7_교육자료
Ji-Woong Choi
 
jBPM 4 BeJUG Event March 20 2009
jBPM 4 BeJUG Event March 20 2009jBPM 4 BeJUG Event March 20 2009
jBPM 4 BeJUG Event March 20 2009
Tom Baeyens
 
How BPM Connects The Internet of Enterprise Things Using Effektif
How BPM Connects The Internet of Enterprise Things Using EffektifHow BPM Connects The Internet of Enterprise Things Using Effektif
How BPM Connects The Internet of Enterprise Things Using Effektif
Tom Baeyens
 
Build and Deployment Initiative - Performance Analysis Summary
Build and Deployment Initiative - Performance Analysis SummaryBuild and Deployment Initiative - Performance Analysis Summary
Build and Deployment Initiative - Performance Analysis Summarycole13ben
 
Digital Transformation: Future Implimentation
Digital Transformation: Future ImplimentationDigital Transformation: Future Implimentation
Digital Transformation: Future Implimentation
Muller Gracio Manalu
 
Bring Your Own People Centric Business Processes
Bring Your Own People Centric Business ProcessesBring Your Own People Centric Business Processes
Bring Your Own People Centric Business Processes
Tom Baeyens
 
Application server vs Web Server
Application server vs Web ServerApplication server vs Web Server
Application server vs Web Server
Gagandeep Singh
 
Presentation about servers
Presentation about serversPresentation about servers
Presentation about servers
Sasin Prabu
 
jBPM Overview & Alfresco Workflows
jBPM Overview &  Alfresco WorkflowsjBPM Overview &  Alfresco Workflows
jBPM Overview & Alfresco Workflows
Francesco Valente
 
Accenture Technology Vision 2012
Accenture Technology Vision 2012Accenture Technology Vision 2012
Accenture Technology Vision 2012
Lars Kamp
 

Viewers also liked (14)

HTTP web server 구현
HTTP web server 구현HTTP web server 구현
HTTP web server 구현
 
소프트웨어 학습 및 자바 웹 개발자 학습 로드맵
소프트웨어 학습 및 자바 웹 개발자 학습 로드맵소프트웨어 학습 및 자바 웹 개발자 학습 로드맵
소프트웨어 학습 및 자바 웹 개발자 학습 로드맵
 
[오픈소스컨설팅]JBoss 5 Detail
[오픈소스컨설팅]JBoss 5 Detail[오픈소스컨설팅]JBoss 5 Detail
[오픈소스컨설팅]JBoss 5 Detail
 
[오픈소스컨설팅]J boss6 7_교육자료
[오픈소스컨설팅]J boss6 7_교육자료[오픈소스컨설팅]J boss6 7_교육자료
[오픈소스컨설팅]J boss6 7_교육자료
 
jBPM 4 BeJUG Event March 20 2009
jBPM 4 BeJUG Event March 20 2009jBPM 4 BeJUG Event March 20 2009
jBPM 4 BeJUG Event March 20 2009
 
How BPM Connects The Internet of Enterprise Things Using Effektif
How BPM Connects The Internet of Enterprise Things Using EffektifHow BPM Connects The Internet of Enterprise Things Using Effektif
How BPM Connects The Internet of Enterprise Things Using Effektif
 
200701251925300.diapo.ejecentralizador
200701251925300.diapo.ejecentralizador200701251925300.diapo.ejecentralizador
200701251925300.diapo.ejecentralizador
 
Build and Deployment Initiative - Performance Analysis Summary
Build and Deployment Initiative - Performance Analysis SummaryBuild and Deployment Initiative - Performance Analysis Summary
Build and Deployment Initiative - Performance Analysis Summary
 
Digital Transformation: Future Implimentation
Digital Transformation: Future ImplimentationDigital Transformation: Future Implimentation
Digital Transformation: Future Implimentation
 
Bring Your Own People Centric Business Processes
Bring Your Own People Centric Business ProcessesBring Your Own People Centric Business Processes
Bring Your Own People Centric Business Processes
 
Application server vs Web Server
Application server vs Web ServerApplication server vs Web Server
Application server vs Web Server
 
Presentation about servers
Presentation about serversPresentation about servers
Presentation about servers
 
jBPM Overview & Alfresco Workflows
jBPM Overview &  Alfresco WorkflowsjBPM Overview &  Alfresco Workflows
jBPM Overview & Alfresco Workflows
 
Accenture Technology Vision 2012
Accenture Technology Vision 2012Accenture Technology Vision 2012
Accenture Technology Vision 2012
 

Similar to Web And App Servers

Deployment with Ruby on Rails
Deployment with Ruby on RailsDeployment with Ruby on Rails
Deployment with Ruby on Rails
Jonathan Weiss
 
Deploying And Monitoring Rails
Deploying And Monitoring RailsDeploying And Monitoring Rails
Deploying And Monitoring Rails
Jonathan Weiss
 
The future of the php development environment
The future of the php development environmentThe future of the php development environment
The future of the php development environment
Jeremy Quinton
 
MySQL High Availability -- InnoDB Clusters
MySQL High Availability -- InnoDB ClustersMySQL High Availability -- InnoDB Clusters
MySQL High Availability -- InnoDB Clusters
Matt Lord
 
Managing your Hadoop Clusters with Ambari
Managing your Hadoop Clusters with AmbariManaging your Hadoop Clusters with Ambari
Managing your Hadoop Clusters with Ambari
DataWorks Summit
 
Accumulo Summit 2016: Apache Accumulo on Docker with YARN Native Services
Accumulo Summit 2016: Apache Accumulo on Docker with YARN Native ServicesAccumulo Summit 2016: Apache Accumulo on Docker with YARN Native Services
Accumulo Summit 2016: Apache Accumulo on Docker with YARN Native Services
Accumulo Summit
 
Installing Hadoop / Spark from scratch
Installing Hadoop / Spark from scratchInstalling Hadoop / Spark from scratch
Installing Hadoop / Spark from scratch
Andrey Vykhodtsev
 
High Availability for OpenStack
High Availability for OpenStackHigh Availability for OpenStack
High Availability for OpenStack
Kamesh Pemmaraju
 
MySQL Fabric
MySQL FabricMySQL Fabric
MySQL Fabric
Mark Swarbrick
 
Modernize your Solaris Apps
Modernize your Solaris AppsModernize your Solaris Apps
Modernize your Solaris AppsAppZero
 
Samza portable runner for beam
Samza portable runner for beamSamza portable runner for beam
Samza portable runner for beam
Hai Lu
 
Lift and shift to sparc cloud
Lift and shift to sparc cloudLift and shift to sparc cloud
Lift and shift to sparc cloud
Riccardo Romani
 
Capybara and cucumber with DSL using ruby
Capybara and cucumber with DSL using rubyCapybara and cucumber with DSL using ruby
Capybara and cucumber with DSL using ruby
Deepak Chandella
 
Use Cases and Integration Scenarios with SAP Adaptive Computing Virtualization
Use Cases and Integration Scenarios with SAP Adaptive Computing VirtualizationUse Cases and Integration Scenarios with SAP Adaptive Computing Virtualization
Use Cases and Integration Scenarios with SAP Adaptive Computing Virtualization
Gunther_01
 
How kafka is transforming hadoop, spark & storm
How kafka is transforming hadoop, spark & stormHow kafka is transforming hadoop, spark & storm
How kafka is transforming hadoop, spark & storm
Edureka!
 
TorqueBox for Rubyists
TorqueBox for RubyistsTorqueBox for Rubyists
TorqueBox for Rubyists
bobmcwhirter
 
AP4R on RubyKaigi2007 (English only)
AP4R on RubyKaigi2007 (English only)AP4R on RubyKaigi2007 (English only)
AP4R on RubyKaigi2007 (English only)
Kato Kiwamu
 
Scaling OpenStack Neutron in Heterogeneous Environments
Scaling OpenStack Neutron in Heterogeneous EnvironmentsScaling OpenStack Neutron in Heterogeneous Environments
Scaling OpenStack Neutron in Heterogeneous Environments
Martin Klein
 
Spark streaming + kafka 0.10
Spark streaming + kafka 0.10Spark streaming + kafka 0.10
Spark streaming + kafka 0.10
Joan Viladrosa Riera
 
OpenStack 2012 fall summit observation - Quantum/SDN
OpenStack 2012 fall summit observation - Quantum/SDNOpenStack 2012 fall summit observation - Quantum/SDN
OpenStack 2012 fall summit observation - Quantum/SDNTe-Yen Liu
 

Similar to Web And App Servers (20)

Deployment with Ruby on Rails
Deployment with Ruby on RailsDeployment with Ruby on Rails
Deployment with Ruby on Rails
 
Deploying And Monitoring Rails
Deploying And Monitoring RailsDeploying And Monitoring Rails
Deploying And Monitoring Rails
 
The future of the php development environment
The future of the php development environmentThe future of the php development environment
The future of the php development environment
 
MySQL High Availability -- InnoDB Clusters
MySQL High Availability -- InnoDB ClustersMySQL High Availability -- InnoDB Clusters
MySQL High Availability -- InnoDB Clusters
 
Managing your Hadoop Clusters with Ambari
Managing your Hadoop Clusters with AmbariManaging your Hadoop Clusters with Ambari
Managing your Hadoop Clusters with Ambari
 
Accumulo Summit 2016: Apache Accumulo on Docker with YARN Native Services
Accumulo Summit 2016: Apache Accumulo on Docker with YARN Native ServicesAccumulo Summit 2016: Apache Accumulo on Docker with YARN Native Services
Accumulo Summit 2016: Apache Accumulo on Docker with YARN Native Services
 
Installing Hadoop / Spark from scratch
Installing Hadoop / Spark from scratchInstalling Hadoop / Spark from scratch
Installing Hadoop / Spark from scratch
 
High Availability for OpenStack
High Availability for OpenStackHigh Availability for OpenStack
High Availability for OpenStack
 
MySQL Fabric
MySQL FabricMySQL Fabric
MySQL Fabric
 
Modernize your Solaris Apps
Modernize your Solaris AppsModernize your Solaris Apps
Modernize your Solaris Apps
 
Samza portable runner for beam
Samza portable runner for beamSamza portable runner for beam
Samza portable runner for beam
 
Lift and shift to sparc cloud
Lift and shift to sparc cloudLift and shift to sparc cloud
Lift and shift to sparc cloud
 
Capybara and cucumber with DSL using ruby
Capybara and cucumber with DSL using rubyCapybara and cucumber with DSL using ruby
Capybara and cucumber with DSL using ruby
 
Use Cases and Integration Scenarios with SAP Adaptive Computing Virtualization
Use Cases and Integration Scenarios with SAP Adaptive Computing VirtualizationUse Cases and Integration Scenarios with SAP Adaptive Computing Virtualization
Use Cases and Integration Scenarios with SAP Adaptive Computing Virtualization
 
How kafka is transforming hadoop, spark & storm
How kafka is transforming hadoop, spark & stormHow kafka is transforming hadoop, spark & storm
How kafka is transforming hadoop, spark & storm
 
TorqueBox for Rubyists
TorqueBox for RubyistsTorqueBox for Rubyists
TorqueBox for Rubyists
 
AP4R on RubyKaigi2007 (English only)
AP4R on RubyKaigi2007 (English only)AP4R on RubyKaigi2007 (English only)
AP4R on RubyKaigi2007 (English only)
 
Scaling OpenStack Neutron in Heterogeneous Environments
Scaling OpenStack Neutron in Heterogeneous EnvironmentsScaling OpenStack Neutron in Heterogeneous Environments
Scaling OpenStack Neutron in Heterogeneous Environments
 
Spark streaming + kafka 0.10
Spark streaming + kafka 0.10Spark streaming + kafka 0.10
Spark streaming + kafka 0.10
 
OpenStack 2012 fall summit observation - Quantum/SDN
OpenStack 2012 fall summit observation - Quantum/SDNOpenStack 2012 fall summit observation - Quantum/SDN
OpenStack 2012 fall summit observation - Quantum/SDN
 

Recently uploaded

FIDO Alliance Osaka Seminar: Passkeys at Amazon.pdf
FIDO Alliance Osaka Seminar: Passkeys at Amazon.pdfFIDO Alliance Osaka Seminar: Passkeys at Amazon.pdf
FIDO Alliance Osaka Seminar: Passkeys at Amazon.pdf
FIDO Alliance
 
Climate Impact of Software Testing at Nordic Testing Days
Climate Impact of Software Testing at Nordic Testing DaysClimate Impact of Software Testing at Nordic Testing Days
Climate Impact of Software Testing at Nordic Testing Days
Kari Kakkonen
 
Communications Mining Series - Zero to Hero - Session 1
Communications Mining Series - Zero to Hero - Session 1Communications Mining Series - Zero to Hero - Session 1
Communications Mining Series - Zero to Hero - Session 1
DianaGray10
 
Introduction to CHERI technology - Cybersecurity
Introduction to CHERI technology - CybersecurityIntroduction to CHERI technology - Cybersecurity
Introduction to CHERI technology - Cybersecurity
mikeeftimakis1
 
National Security Agency - NSA mobile device best practices
National Security Agency - NSA mobile device best practicesNational Security Agency - NSA mobile device best practices
National Security Agency - NSA mobile device best practices
Quotidiano Piemontese
 
Alt. GDG Cloud Southlake #33: Boule & Rebala: Effective AppSec in SDLC using ...
Alt. GDG Cloud Southlake #33: Boule & Rebala: Effective AppSec in SDLC using ...Alt. GDG Cloud Southlake #33: Boule & Rebala: Effective AppSec in SDLC using ...
Alt. GDG Cloud Southlake #33: Boule & Rebala: Effective AppSec in SDLC using ...
James Anderson
 
The Future of Platform Engineering
The Future of Platform EngineeringThe Future of Platform Engineering
The Future of Platform Engineering
Jemma Hussein Allen
 
The Art of the Pitch: WordPress Relationships and Sales
The Art of the Pitch: WordPress Relationships and SalesThe Art of the Pitch: WordPress Relationships and Sales
The Art of the Pitch: WordPress Relationships and Sales
Laura Byrne
 
SAP Sapphire 2024 - ASUG301 building better apps with SAP Fiori.pdf
SAP Sapphire 2024 - ASUG301 building better apps with SAP Fiori.pdfSAP Sapphire 2024 - ASUG301 building better apps with SAP Fiori.pdf
SAP Sapphire 2024 - ASUG301 building better apps with SAP Fiori.pdf
Peter Spielvogel
 
GraphSummit Singapore | The Future of Agility: Supercharging Digital Transfor...
GraphSummit Singapore | The Future of Agility: Supercharging Digital Transfor...GraphSummit Singapore | The Future of Agility: Supercharging Digital Transfor...
GraphSummit Singapore | The Future of Agility: Supercharging Digital Transfor...
Neo4j
 
Why You Should Replace Windows 11 with Nitrux Linux 3.5.0 for enhanced perfor...
Why You Should Replace Windows 11 with Nitrux Linux 3.5.0 for enhanced perfor...Why You Should Replace Windows 11 with Nitrux Linux 3.5.0 for enhanced perfor...
Why You Should Replace Windows 11 with Nitrux Linux 3.5.0 for enhanced perfor...
SOFTTECHHUB
 
Epistemic Interaction - tuning interfaces to provide information for AI support
Epistemic Interaction - tuning interfaces to provide information for AI supportEpistemic Interaction - tuning interfaces to provide information for AI support
Epistemic Interaction - tuning interfaces to provide information for AI support
Alan Dix
 
Generative AI Deep Dive: Advancing from Proof of Concept to Production
Generative AI Deep Dive: Advancing from Proof of Concept to ProductionGenerative AI Deep Dive: Advancing from Proof of Concept to Production
Generative AI Deep Dive: Advancing from Proof of Concept to Production
Aggregage
 
GDG Cloud Southlake #33: Boule & Rebala: Effective AppSec in SDLC using Deplo...
GDG Cloud Southlake #33: Boule & Rebala: Effective AppSec in SDLC using Deplo...GDG Cloud Southlake #33: Boule & Rebala: Effective AppSec in SDLC using Deplo...
GDG Cloud Southlake #33: Boule & Rebala: Effective AppSec in SDLC using Deplo...
James Anderson
 
20240605 QFM017 Machine Intelligence Reading List May 2024
20240605 QFM017 Machine Intelligence Reading List May 202420240605 QFM017 Machine Intelligence Reading List May 2024
20240605 QFM017 Machine Intelligence Reading List May 2024
Matthew Sinclair
 
FIDO Alliance Osaka Seminar: FIDO Security Aspects.pdf
FIDO Alliance Osaka Seminar: FIDO Security Aspects.pdfFIDO Alliance Osaka Seminar: FIDO Security Aspects.pdf
FIDO Alliance Osaka Seminar: FIDO Security Aspects.pdf
FIDO Alliance
 
Essentials of Automations: The Art of Triggers and Actions in FME
Essentials of Automations: The Art of Triggers and Actions in FMEEssentials of Automations: The Art of Triggers and Actions in FME
Essentials of Automations: The Art of Triggers and Actions in FME
Safe Software
 
LF Energy Webinar: Electrical Grid Modelling and Simulation Through PowSyBl -...
LF Energy Webinar: Electrical Grid Modelling and Simulation Through PowSyBl -...LF Energy Webinar: Electrical Grid Modelling and Simulation Through PowSyBl -...
LF Energy Webinar: Electrical Grid Modelling and Simulation Through PowSyBl -...
DanBrown980551
 
Securing your Kubernetes cluster_ a step-by-step guide to success !
Securing your Kubernetes cluster_ a step-by-step guide to success !Securing your Kubernetes cluster_ a step-by-step guide to success !
Securing your Kubernetes cluster_ a step-by-step guide to success !
KatiaHIMEUR1
 
20240607 QFM018 Elixir Reading List May 2024
20240607 QFM018 Elixir Reading List May 202420240607 QFM018 Elixir Reading List May 2024
20240607 QFM018 Elixir Reading List May 2024
Matthew Sinclair
 

Recently uploaded (20)

FIDO Alliance Osaka Seminar: Passkeys at Amazon.pdf
FIDO Alliance Osaka Seminar: Passkeys at Amazon.pdfFIDO Alliance Osaka Seminar: Passkeys at Amazon.pdf
FIDO Alliance Osaka Seminar: Passkeys at Amazon.pdf
 
Climate Impact of Software Testing at Nordic Testing Days
Climate Impact of Software Testing at Nordic Testing DaysClimate Impact of Software Testing at Nordic Testing Days
Climate Impact of Software Testing at Nordic Testing Days
 
Communications Mining Series - Zero to Hero - Session 1
Communications Mining Series - Zero to Hero - Session 1Communications Mining Series - Zero to Hero - Session 1
Communications Mining Series - Zero to Hero - Session 1
 
Introduction to CHERI technology - Cybersecurity
Introduction to CHERI technology - CybersecurityIntroduction to CHERI technology - Cybersecurity
Introduction to CHERI technology - Cybersecurity
 
National Security Agency - NSA mobile device best practices
National Security Agency - NSA mobile device best practicesNational Security Agency - NSA mobile device best practices
National Security Agency - NSA mobile device best practices
 
Alt. GDG Cloud Southlake #33: Boule & Rebala: Effective AppSec in SDLC using ...
Alt. GDG Cloud Southlake #33: Boule & Rebala: Effective AppSec in SDLC using ...Alt. GDG Cloud Southlake #33: Boule & Rebala: Effective AppSec in SDLC using ...
Alt. GDG Cloud Southlake #33: Boule & Rebala: Effective AppSec in SDLC using ...
 
The Future of Platform Engineering
The Future of Platform EngineeringThe Future of Platform Engineering
The Future of Platform Engineering
 
The Art of the Pitch: WordPress Relationships and Sales
The Art of the Pitch: WordPress Relationships and SalesThe Art of the Pitch: WordPress Relationships and Sales
The Art of the Pitch: WordPress Relationships and Sales
 
SAP Sapphire 2024 - ASUG301 building better apps with SAP Fiori.pdf
SAP Sapphire 2024 - ASUG301 building better apps with SAP Fiori.pdfSAP Sapphire 2024 - ASUG301 building better apps with SAP Fiori.pdf
SAP Sapphire 2024 - ASUG301 building better apps with SAP Fiori.pdf
 
GraphSummit Singapore | The Future of Agility: Supercharging Digital Transfor...
GraphSummit Singapore | The Future of Agility: Supercharging Digital Transfor...GraphSummit Singapore | The Future of Agility: Supercharging Digital Transfor...
GraphSummit Singapore | The Future of Agility: Supercharging Digital Transfor...
 
Why You Should Replace Windows 11 with Nitrux Linux 3.5.0 for enhanced perfor...
Why You Should Replace Windows 11 with Nitrux Linux 3.5.0 for enhanced perfor...Why You Should Replace Windows 11 with Nitrux Linux 3.5.0 for enhanced perfor...
Why You Should Replace Windows 11 with Nitrux Linux 3.5.0 for enhanced perfor...
 
Epistemic Interaction - tuning interfaces to provide information for AI support
Epistemic Interaction - tuning interfaces to provide information for AI supportEpistemic Interaction - tuning interfaces to provide information for AI support
Epistemic Interaction - tuning interfaces to provide information for AI support
 
Generative AI Deep Dive: Advancing from Proof of Concept to Production
Generative AI Deep Dive: Advancing from Proof of Concept to ProductionGenerative AI Deep Dive: Advancing from Proof of Concept to Production
Generative AI Deep Dive: Advancing from Proof of Concept to Production
 
GDG Cloud Southlake #33: Boule & Rebala: Effective AppSec in SDLC using Deplo...
GDG Cloud Southlake #33: Boule & Rebala: Effective AppSec in SDLC using Deplo...GDG Cloud Southlake #33: Boule & Rebala: Effective AppSec in SDLC using Deplo...
GDG Cloud Southlake #33: Boule & Rebala: Effective AppSec in SDLC using Deplo...
 
20240605 QFM017 Machine Intelligence Reading List May 2024
20240605 QFM017 Machine Intelligence Reading List May 202420240605 QFM017 Machine Intelligence Reading List May 2024
20240605 QFM017 Machine Intelligence Reading List May 2024
 
FIDO Alliance Osaka Seminar: FIDO Security Aspects.pdf
FIDO Alliance Osaka Seminar: FIDO Security Aspects.pdfFIDO Alliance Osaka Seminar: FIDO Security Aspects.pdf
FIDO Alliance Osaka Seminar: FIDO Security Aspects.pdf
 
Essentials of Automations: The Art of Triggers and Actions in FME
Essentials of Automations: The Art of Triggers and Actions in FMEEssentials of Automations: The Art of Triggers and Actions in FME
Essentials of Automations: The Art of Triggers and Actions in FME
 
LF Energy Webinar: Electrical Grid Modelling and Simulation Through PowSyBl -...
LF Energy Webinar: Electrical Grid Modelling and Simulation Through PowSyBl -...LF Energy Webinar: Electrical Grid Modelling and Simulation Through PowSyBl -...
LF Energy Webinar: Electrical Grid Modelling and Simulation Through PowSyBl -...
 
Securing your Kubernetes cluster_ a step-by-step guide to success !
Securing your Kubernetes cluster_ a step-by-step guide to success !Securing your Kubernetes cluster_ a step-by-step guide to success !
Securing your Kubernetes cluster_ a step-by-step guide to success !
 
20240607 QFM018 Elixir Reading List May 2024
20240607 QFM018 Elixir Reading List May 202420240607 QFM018 Elixir Reading List May 2024
20240607 QFM018 Elixir Reading List May 2024
 

Web And App Servers

  • 2. 1 Simple Rails Setup  One Rails instance handles all requests Rails is single-threaded: There is only one concurrent request Sapna Solutions
  • 3. 2 Rails Setup Sapna Solutions
  • 4. 3 Typical Rails Setup  A load-balancer distributes the incoming requests  Some load-balancers will deliver static requests themselves  Several Rails instances handle all requests  Number of concurrent requests equals number of Rails instances Sapna Solutions
  • 5. 4 Deployment Questions Sapna Solutions
  • 6. 5 Deployment Questions Sapna Solutions
  • 7. 6 SERVERS Rails Application Server Proxy/Web Server  FastCGI  Apache2  Mongrel  Nginx  mod_rails / Phussion  Lighttpd Passenger  HA-Proxy  JRuby + Glassfish & Co. Sapna Solutions
  • 8. FastCGI 7  Protocol to communicate with long-running CGI applications  Usage of either mod_fcgi with Apache 1.3 or mod_fcgi with Lighttpd  Proxy local and remote FastCGI instances  Oldest way of deploying Rails  Deprecated and unstable  Hard to debug (FastCGI protocol) Sapna Solutions
  • 9. FastCGI 8 Sapna Solutions
  • 11. 10 Mongrel Sapna Solutions
  • 12. 11 Mongrel  Developed by Zed Shaw as an alternative to FastCGI  Complete HTTP-Server that can load arbitrary Ruby-servlets  Built-in Rails support Sapna Solutions
  • 13. 12 Mongrel Sapna Solutions
  • 14. 13 Mongrel Sapna Solutions
  • 15. 14 Mongrel  Very robust  Strict HTTP parser  Easy to debug (HTTP!)  Used to be defacto deployment setup with Apache 2.2 and mod_proxy_balancer  Can be a bit difficult to setup (mongrel_cluster, ports, Apache)  Not so easy on mass/virtual hosting Sapna Solutions
  • 16. 15 Mod_rails a.k.a Phusion Passenger Sapna Solutions
  • 17. Mod_rails a.k.a Phusion 16 Passenger  Module for Apache 2.2 (and Nginx)  Allows Apache to control Rails instances  Apache starts and stops application instances depending on the application load  Able to run any Rack-compatible Ruby application (Merb, Sinatra & Co.)  Only manages Rails on one host - no remote instances  Combine with HTTP-Proxy / balancing solution Sapna Solutions
  • 18. 17 Install Phusion Passenger  Install Apache module  Load and activate in Apache Sapna Solutions
  • 19. 18 Customized Phusion Passenger Sapna Solutions
  • 20. 19 Control Phusion Passenger Restart after deployment: Sapna Solutions
  • 21. 20 Phusion Passenger Sapna Solutions
  • 22. 21 Phusion Passenger Sapna Solutions
  • 23. 22 Phusion Passenger  Ready for production  Makes setup easier – on the single machine level  Multiple servers still require load balancer  Suitable for mass-hosting  upcoming standard way of deploying Rails Sapna Solutions
  • 24. 23 Apache 2.2  Apache 2.2 introduced mod_proxy_balancer  mod_proxy_balancer can speak to multiple backends and balance requests  Apache can acts as a pure proxy or can also serve static files Sapna Solutions
  • 25. 24 Setups Recommended Sapna Solutions
  • 26. 25 Small Site Sapna Solutions
  • 27. 26 Medium Site Sapna Solutions
  • 29. Heavy Static Files 28 Sapna Solutions
  • 31. 30 Application Server Handler Sapna Solutions
  • 32. 31 RACK Sapna Solutions
  • 33. 32 Rack Handler Sapna Solutions
  • 34. 33 Rack Supports Sapna Solutions
  • 35. 34 What are we using?  Speedy Rails (vps213 and vps214) (Canada)  Apache2  Ruby Enterprise(1.8)  Phusion Passenger  MySql  Build, Staging and Production Environments  Every RAILS APP log maintained Sapna Solutions
  • 36. Where our applications reside? 35 Login to VPS 214 Sudo su - deploy cd /var/www/apps/ Sapna Solutions
  • 37. 36 How to debug? Host <domainname> Checkout ip address serving it APACHE CONF file (path to app) Sapna Solutions
  • 38. 37 DEPLOYMENT Sapna Solutions
  • 40. 39 We prefer Sapna Solutions
  • 41. 40 How to DEPLOY? CAPISTRANO CUSTOM TASKS EASIEST AND TRUSTED WAY Sapna Solutions
  • 43. 42 What does Capistrano do? Sapna Solutions