Sonntag, 7. April 2013

Set up an apache/httpd server on fedora 18 for raspberry pi

Hello!

Setting up an apache server on raspberry with fedora 18 is straight forward.

Just run the following command (as root):
# yum install httpd

After that, you probably want to start apache and have it started at bootup:
# service httpd start
# systemctl enable httpd.service


To unblock port 80 in fedora's firewall (make the server available from outside), run

# firewall-cmd --add-port=80/tcp
and (to make it permanent. i.e. surviving reboots)
# firewall-cmd --permanent --add-port=80/tcp

You may also want to install the following packages
  • mysql mysql-server
    installs mysql and its database server. Autostart by running
    # systemctl enable mysqld.service
  • php
    install php 5
  • php-mysql
    installs mysql support for php
by running
# yum install <packagename>
where you replace <packagename> with one or more of the ones given above.

After having installed all of them, you're running a complete LAMP (linux, apache, mysql, php) server on your raspberry.

Congratulations!

[UPDATE Apr. 28 2013] Since solely running "firewall-cmd" will not survive any restarts, I added the additional command including "--permanent" option to the blog post.

Keine Kommentare:

Kommentar veröffentlichen

Thanks for spending time on giving me feedback. I really appreciate it :)