Skip to Content
Learning Raspberry Pi
book

Learning Raspberry Pi

by Samarth Shah, Serge Schneider
April 2015
Beginner
258 pages
5h 30m
English
Packt Publishing
Content preview from Learning Raspberry Pi

Installing a web server

The first instinct may be to install Apache. However, nginx performs better on lower-end hardware. It should be noted that Apache can work just as well if the unnecessary plugins are removed and Apache is configured appropriately. For something that works fairly well out of the box, nginx is a great start.

  1. First, install nginx and php with an accelerator and a MySQL server with the following command:
    # apt-get install nginx php5-fpm php5-mysql php-apc mysql-server
    

    Note

    You will be prompted to set a password for MySQL; please make sure you remember it, as you will need it later.

  2. Then, start the nginx service:
    # service nginx start
    
  3. In order to ensure nginx is working, open up a browser and connect to the Raspberry Pi's IP. You ...
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Start your free trial

You might also like

Mastering the Raspberry Pi

Mastering the Raspberry Pi

Warren W. Gay
Raspberry Pi Hacks

Raspberry Pi Hacks

Ruth Suehle, Tom Callaway

Publisher Resources

ISBN: 9781783982820