PHP Fog Title Slide Presentation Cloud платформата PHP Fog предоставя интерфейс за инсталиране на готови PHP приложения, както и deploy на собствени PHP сайтове. Освен платените версии, PHP Fog предлага и напълно безплатна версия, която позволява създаване на до 3 приложения в облака. Тук са качени презентация и видео, в които се разглеждат детайлно платформата на PHP Fog, заедно с демо на това как да си напишем и качим собствено приложение, както и демо с използването на едно от готовите приложения, които PHP Fog ни предоставя.

Видео лекция за PHP Fog

Материали за PHP Fog

Video icon

Сваляне на видеото
с лекцията (mp4)

PowerPoint presentation icon

Сваляне на PowerPoint презентацията

Съдържание на лекцията

What is PHP Fog?

  • Cloud-based PHP hosting service
  • Founded in August 2010 by Lucas Carlson
  • Rock-solid cloud platform for PHP
  • Fast, reliable, easy and scalable hosting for PHP
  • Reliable by design (Runs on Amazon EC2)
  • Fast performance
  • Very easy deployment
  • Jumpstart applications
  • Custom applications (deploying using Git)

Installing Ready-to-Use Applications and Frameworks

  • Ready to use PHP applications and PHP Frameworks with just few clicks
  • Few seconds and you have fully functional application in the cloud
  • Full access to the application administration
  • Full access to the database and the files
  • 9 Ready-to-use PHP applications
  • 11 Pre-installed PHP frameworks
  • Large variety of ready-to-use applications: CMS, Blogs, Wikis, CRM, Facebook apps, etc.
  • A lot of pre-installed PHP frameworks Including Zend, CakePHP, Yii, CodeIngniter, etc.

PHP Fog Platform Overview

PHP Fog – Cache

  • The Cache layer (Vanish) intercepts the request and can deliver lightning-fast responses
  • 50-80% of responses can be served from the cache, ensuring responsiveness and diminishing server load to an absolute minimum
  • Varnish is a state-of-the-industry caching solution for web applications
  • Varnish ensures that your PHP applications serve cached responses intelligently

PHP Fog – Load Balancer

  • PHP Fog load balancing uses Nginx (free, open-source, high-performance web server)
  • Directs requests to the application server best able to handle the requests
  • If a server is unavailable, it is routed to a new server thus improves the reliability of your app
  • When you add more servers they are automatically made available and the load balancer is automatically updated

PHP Fog – App Servers

  • Each and every app server is a dedicated Linux server running an Apache instance
  • Apache serving 59% of web content online
  • mod_php provides robust PHP-scripting language support for the Apache web host
  • APC is an accelerator & optimizer so your PHP code gets compiled and runs fast every time
  • The locked-down environment ensures your application is secure by default

PHP Fog – Database

  • All applications get a primary and passive MySQL database
  • The primary database server is synchronized to a passive database slave which provides an up-to-the-minute snapshot of your MySQL databases
  • The database slave is used for application fail-over in case the primary server isn’t behaving properly
  • The database is easily scalable

Working with Git and SSH Keys

Git

  • Source-control system (Like SVN, TFS, etc.)
  • Can work with local and remote repositories
  • Git Bash – command line interface for Git
  • Free (open source)
  • Has Windows versions (msysgit , TortoiseGIT)

Generate SSH Keys

Use Git in PHP Fog

In order to access the source code for your application with PHP Fog, you'll need to use the generated SSH key with your Git client and your PHP Fog account from the following link: http://phpfog.com/user_session/new#/ssh_keys

Creating and Deploying Custom PHP Applications

PHP Fog Custom Applications

  • Write your own PHP application in the cloud
  • You need Git and SSH key created and saved in your local machine and in the PHP Fog
  • You have access to MySQL database
  • You have full source code access
  • You can use add-ons, custom environment variables, domains, permissions, etc.

Environment Variables

  • Environment variables let you specify data that you do not want in your source code repository (like passwords)
  • You can access these variables in PHP through the getenv() function

MySQL Databases in PHP Fog

  • All custom applications in PHP Fog have their own easy-to-use MySQL database
  • All connection details can be found in the "Database" tab of your application in PHP Fog
  • You can administrate your database using phpMyAdmin (web-based mysql admin tool)
  • http://myadmin.phpfogapp.com/

PHP Fog Add-Ons

PHP Fog Add-Ons – MongoLab

  • Cloud-based database provider that hosts MongoDB databases on various cloud providers such as EC2 and Rackspace
  • Replication, backups, monitoring and uptime
  • Easy-to-use web administration tools and developer APIs
  • Homepage: http://mongolab.com

PHP Fog Add-Ons – MongoHQ

  • Hosted database solution for getting applications up and running on MongoDB, fast.
  • Homepage: https://mongohq.com

PHP Fog Add-Ons – ClearDB

  • Reliable, fault tolerant database-as-a-service for your MySQL powered applications
  • It's designed around the premise of failure to ensure that your database is available and secure, no matter what
  • Homepage: http://cleardb.com

PHP Fog Add-Ons – NewRelic

  • Offers application performance monitoring and alerting for applications application servers
  • Homepage: http://newrelic.com/

PHP Fog Add-Ons – Blitz

  • Self-service cloud based performance testing
  • Built for API, cloud, web and mobile developers
  • Helps you ensure: Performance, Scalability, Security
  • Homepage: http://blitz.io/

PHP Fog Add-Ons – Mailgun

  • Programmable email platform
  • Send and receive messages
  • Create mailboxes
  • Create email campaigns
  • Homepage: http://mailgun.net

PHP Fog Add-Ons – CloudMailin

  • You are given an email address that will forward any incoming message to your app
  • You can also seamlessly check the delivery status of each of your incoming emails via the dashboard, bounce emails that you do not wish to receive and use your own domain name.
  • Homepage: http://cloudmailin.com/

PHP Fog Add-Ons – IronWorker

  • Easy-to-use and massively scalable task queue
  • Gives cloud developers a simple way to offload front-end tasks and manage their scheduled jobs and background processing
  • Homepage: http://iron.io/products/worker

PHP Fog Add-Ons – IronMQ

  • Flexible, scalable, durable messaging system
  • Lets different parts of a cloud app connect with and scale independently from other internal and external processes
  • Homepage: http://iron.io/products/mq

PHP Fog Useful Links

Homework

  • Create your own PHP Fog account
  • Install two ready-to-use applications (e.g. Wordpress, Joomla, MediaWiki, etc.)
  • Configure the applications as you wish and change their default theme to one that you prefer the most
  • Write and deploy simple PHP application that uses at least one MySQL table
  • As a result of your homework submit the sources and the links of your PHP Fog apps

View Comments