Giter Site home page Giter Site logo

bosh-sample-release's Introduction

This is a sample release repository for BOSH that deploys a three tier LAMP application: a wordpress blog which consists of a number of apache servers running php & wordpress, fronted by nginx, and using one mysql database for storage.

The sample is made up of three jobs:
- mysql
- wordpress
  which consist of apache + php5 + wordpress
- nginx

The repository also contains a sample deployment file (wordpress.yml) which you can use to deploy the jobs that makes up the application, after updating the "networks" section.

There are three main directories in the release:
- src
  this is the source code for the packages
- packages
  this is instructions on how to compile the source into binaries
- jobs
  this is scripts and configuration files required to run the packages

A package is made up of the following files:
- spec
  defines the package name, the source file it uses and optionally other
  packages it depends on to compile
- pre_packaging
  an optional file that prepares the source for the packaging script
- packing
  the script that compiles the source into binaries

A job is made up of the following files:
- spec
  defines the job name, package dependencies and how to convert templates
  into files
- monit
  the monit file which defines how to start and stop the job
- templates
  a directory which contain the scripts and config files for the job

The wordpress job consist of four packages: apache2, php5, wordpress and mysqlclient.
Normally php is compiled into apache, but here it is kept in its own package so that you can easily upgrade one without the other.

To deploy the sample application use the following command sequence:

bosh create release (name it wordpress)
bosh upload release
edit deployment manifest (wordpress.yml)
bosh deployment wordpress.yml
bosh deploy


TODO
use HyperDB & MySQL master/slave replication
http://wordpress.org/extend/plugins/hyperdb/installation/
http://dev.mysql.com/doc/refman/5.1/en/replication-howto.html

bosh-sample-release's People

Contributors

olegshaldybin avatar pmenglund avatar

Stargazers

 avatar

Watchers

 avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.