JumpBox for LAMP Deployment
Bookmark this link to keep a permanent link to this page.
Welcome to the JumpBox for LAMP Deployment! You can use this JumpBox as a tool to quickly, safely
and easily deploy web applications on your local network. Alternatively, it can help you develop your own web
application. This JumpBox includes the following software and for each language, the appropriate MySQL bindings
and a handful of common libraries.
To use this JumpBox, you will need the following:
- An SSH client, and a basic knowledge of how to use it.
- A basic understanding of how to use Linux.
- Some familiarity with web applications.
How to Deploy a Web Application
You'll need the application's installation archive (e.g., zip file or tarball) and access to its
- SCP the installation archive into the directory
/home/admin on the JumpBox.
- scp ARCHIVE.zip email@example.com:
- SSH in to the JumpBox.
- ssh firstname.lastname@example.org
- Change directory to
- cd /var/data/public
- Unpack the installation archive.
- unzip ~/ARCHIVE.zip
- tar zxf ~/ARCHIVE.tgz
- tar yxf ~/ARCHIVE.tar.bz2
- Set appropriate ownership on the unpacked files.
- sudo chown -R admin:www-data *
- Unless the application uses PHP, you will probably need to set the CGI scripts to be executable.
- find . -type f | grep '\.(py|pl|rb|cgi)$' | xargs chmod +x
- Follow your application's setup instructions. You may need the following parameters:
- Database Host: localhost
- Database Name: mydb
- Database User: myuser
- Database Pass: (Specified during setup)
- Document Root: /var/data/public
- Base URL: http://18.104.22.168/public
- If the application requires a directory (say
directory/name) to be made writable, you may do so as follows:
- chmod -R g+w directory/name
- If the application needs to store permanent state in files away from the webserver, it may do so in
How to Develop a Web Application
- Use SSH and SCP to copy files to, and edit files on the JumpBox. Standard editors such as
jed are available.
- Give files the appropriate ending (
.cgi). Set CGI scripts to be executable.
- Write your application to use the directories and database described above (or create another database as
- If you wish, you can modify the following system configuration files. When you back up the JumpBox, these
settings will be saved:
For MySQL and PHP, you will need to use
sudo to become root before editing the files:
- sudo vi /etc/mysql/my.cnf
- The JumpBox backup functionality will backup the aformentioned config files, all databases,
/var/data/private. Anything else will be lost!
- phpMyAdmin is available here. You can create users and databases as needed. Do not delete any existing user or database.
- This JumpBox is based on Ubuntu. If you need to install dependencies, you may use
in the following examples.
- Update the apt database (do this first):
- sudo apt-get update
- Search for the Perl DateTime module:
- sudo apt-cache search perl | grep -i DateTime
- Install the Perl DateTime module:
- sudo apt-get -y install libdatetime-perl
- Documentation Links:
- This documentation page should go away once you place content under the webserver root. If this does not
happen as expected, you can permanently disable this documentation by executing the following command; but make
sure you print or save a copy of this documentation somewhere before you do.
- touch /var/data/private/disable-index-rewrite