-
Notifications
You must be signed in to change notification settings - Fork 1
The server
The app is currently running at http://37.59.35.155/
You can SSH to the box at 37.59.35.155. If you need an account but don't have one, contact Tero.
- Intel Xeon i7 4x2.66+GHz (2x hyperthreading)
- 24Gb RAM
- 2x120Gb SSD (soft raid 1)
- 64bit Ubuntu Server 12.04 "Precise Pangolin"
- OpenJDK 64-Bit Server VM (build 22.0-b10, mixed mode)
- Vert.x 1.2.3.final
- Nginx 1.1.19
There is a system-wide JDK installation, installed via apt.
Vert.x is installed to the home directory of the application user, in /home/reittiopas/vert.x
The application is running under the application user's privileges, from the directory /home/reittiopas/app. A separate staging instance is running from the directory /home/reittiopas/staging/app
There are upstart configuration files for managing the application procesess in /etc/init/reittiopas.conf and /etc/init/reittiopas-dev.conf. The application user has been given the privilege to manage these processes (defined in /etc/sudoers), so the following commands are available:
sudo start reittiopas
sudo stop reittiopas
sudo restart reittiopas
sudo status reittiopas
sudo start reittiopas-dev
sudo stop reittiopas-dev
sudo restart reittiopas-dev
sudo status reittiopas-dev
There is a bare Git repository in /home/reittiopas/repo, which can be added as a remote repo for deployments. It has a post-receive hook, which checks the latest master out to /home/reittiopas/app and restarts the upstart service each time something is pushed. Correspondingly for the dev version, there is a bare Git repo /home/reittiopas/dev/repo and checkout of the dev branch at /home/reittiopas/dev/app See the Deployment steps.
Vert.x is logging via JUL to /home/reittiopas/logs
Everything is served by Nginx, which is running on port 80. It serves static files directly, and reverse proxies the rest to localhost:8080 for production and localhost:8090 for dev.
Nginx configurations are in /etc/nginx/nginx.conf and /etc/nginx/sites-enabled/default. Access/error logs are in /var/log/nginx.
Nginx can be managed through service scripts (sudo is needed here. This cannot be done by the application user):
sudo service nginx start
sudo service nginx stop
sudo service nginx restart
sudo service nginx status
- Set up zero-downtime deploys?