-
Notifications
You must be signed in to change notification settings - Fork 4
Deployment
This page is meant to be a end-to-end instruction on how to get up and running with the Marketplace. But for now, it is simply a place to document how the application is currently deployed.
Current production setup is:
- 1 EC2 Large for HTTP server
- 1 EC2 Small for files storage (Drupal files directory is symlinked to it).
- 1 RDS db.m1.large instance (DB server)
- 1 load balancer
This configuration is not required to run Marketplace but is designed to survive traffic spikes and can be easily extended (for example, by adding more HTTP servers to the load balancer). In case of multi-server config, additional deployment tools will be required to sync codebase between HTTP servers. S3 storage is considered for static content, however not implemented yet.
- Ubunutu
- Ubuntu 10.04.3 LTS x86_64 (64Bit Ubuntu server version used since EC2 Large is 64bit architecture. 32Bit Ubuntu version is used with EC2 small).
Note, options below are not mandatory to run CC marketplace site. It needs to meet standard Drupal 7 requirements as listed here: http://drupal.org/requirements at least. However, some of the server software (like using NGinx instead of Apache, APC) affects Drupal's and site performance.
- Using MySQL
- On production, DB is installed to RDS db.m1.large currently. For DEV environments can be hosted on the same server as application.
- MySQL: 5.1.57 via TCP/IP
- max allowed packet set to 32M
- PHP Version 5.3.2-1ubuntu4.7ppa5~lucid1
- FPM/FastCGI
- memory_limit set to 256M (required for some admin operations).
- APC is enabled with default options.
- FastCGI is used because of the use of Nginx.
- (what version?)
- (how installed?)
- (any specific config changes?)
Though Drupal is most often used with Apache, Nginx is a fast, non-blocking web server.
- 1.0.10
- (how installed?)
- (any specific config changes?)
- Main config:
/etc/nginx/site-enabled/civic
Not set up yet but being considered. This would greatly help anonymous traffic.
Not set up yet but being considered. This would help improve both performance and relevancy for searching.
Drush is extremely helpful in managing a Drupal site form the command line.
- Install
- Installed pear first.
sudo apt-get install php-pear
- Upgrade pear.
sudo pear upgrade
- Then following instructions on Drush project page.
- Had to do with
sudo
unfortunately, though Drush should work without sudo.
- Had to do with
- Installed pear first.
- Drupal requires that cron.php be run on a regular basis.
- Runs as part of Drupal 7 core (started when someone visits the site).
- There is no any special backup rules configured for production instance. DB backups are available as point-in-time snapshots of the RDS instance (stored for last 8 days). Code is stored in Github and local Git repositories.
- There are no backup rules configured for EC2 instances. Manual backup can be performed via taking snapshot of the instance needed.