-
Notifications
You must be signed in to change notification settings - Fork 8
AMI server
Based on the Amazon Linux x64, this server is bundled with Node.js , Nginx and PHP5 - setup and ready to use.
Designed with minimal footprint and modular architecture in mind, localhost is driven by the node app Drone that provides a simplified yet agile setup that:
- Uses the cluster library from the Node.js API to reach maximum performance in a multi-core environment.
- Can redirect by proxy to other node apps, websites run with nginx or other web destination on other servers.
You can get it from here: https://aws.amazon.com/amis/drone-server
- git v1.7.4.5
- node v0.8.2 (stable)
- nginx v1.0.15
- php v5.3.13
- npm v1.1.37
- express v2.5.11
- mongoose v2.7.1
- http-proxy v0.8.1
Upon start up initialise the nginx server and start the drone daemon (that creates the cluster and proxy):
sudo /etc/init.d/nginx start
sudo start drone
sudo monit -d 60 -c /etc/monit/drone
Drone is checked out from the public repo locally at /local/drone/ and it's advisable to pull the latest version straight away. You'll also need to configure the routes based on your websites, available in the ./config/routes.js sub-folder.
The nginx server is running on port 3000 and you'll need to setup the virtual hosts and configure the websites running on that server to listen to the same port.
Root website folder, that is expected to host all the websites is: /var/www/
#upstart commands
sudo start drone
sudo status drone
sudo stop drone
#the commands above are shortcuts of initctl:
initctl start drone
initctl status drone
#to check if the upstart conf is valid
initctl check-config
#to reload upstart configs
initctl reload-configuration
#monit command
sudo monit
sudo monit start drone
Created by Makis Tracend (@tracend) (originally) for K&D Interactive (www.kdi.co)
Distributed freely under the Creative Commons license (Attribution 3.0 Unported).