Installing Server Software Packages

In order to run the production environment, your server will need several packages: Zip, Java Run-Time, MongoDB, and Nginx.

Using the terminal, log in to the server using the connection script.

~/connect_ssh

Once logged in, update the Debian distribution.

sudo apt-get update

Enter the user password to access administrator tasks. You will need to do this for every SSH session. If your password is stored in Keychain, you can copy it and paste directly into the terminal.

Installing Zip

Zip package will be used to un-archive the production build of your application.

sudo apt-get install -y zip

Installing Java Run-Time Environment

Java Run-Time will be used to run your Scala/Play application.

sudo apt-get install -y default-jre

Installing MongoDB

MongoDB engine will provide the database for your application.

Import public GPG Key.

wget -qO - https://www.mongodb.org/static/pgp/server-4.2.asc | sudo apt-key add -

Install the latest version of MongoDB.

sudo apt-get install -y mongodb

Installing Nginx

Nginx will work as a proxy web server passing all requests from port 80 and 443 to the application port 9000 as well as providing a secure connection for the client.

sudo apt-get install -y nginx

Test by opening a browser on your machine and pointing it to http://server-ip, where server-ip is the IP address of your server. For example, http://127.2.8.8.

You should see the Welcome to nginx! page.


References


Next: Connecting Domain to the Server