Your SlideShare is downloading. ×
0
Speed up your development environment PHP + Nginx + Fedora + PG
Speed up your development environment PHP + Nginx + Fedora + PG
Speed up your development environment PHP + Nginx + Fedora + PG
Speed up your development environment PHP + Nginx + Fedora + PG
Speed up your development environment PHP + Nginx + Fedora + PG
Speed up your development environment PHP + Nginx + Fedora + PG
Speed up your development environment PHP + Nginx + Fedora + PG
Speed up your development environment PHP + Nginx + Fedora + PG
Speed up your development environment PHP + Nginx + Fedora + PG
Speed up your development environment PHP + Nginx + Fedora + PG
Speed up your development environment PHP + Nginx + Fedora + PG
Speed up your development environment PHP + Nginx + Fedora + PG
Upcoming SlideShare
Loading in...5
×

Thanks for flagging this SlideShare!

Oops! An error has occurred.

×
Saving this for later? Get the SlideShare app to save on your phone or tablet. Read anywhere, anytime – even offline.
Text the download link to your phone
Standard text messaging rates apply

Speed up your development environment PHP + Nginx + Fedora + PG

2,648

Published on

Published in: Technology
0 Comments
0 Likes
Statistics
Notes
  • Be the first to comment

  • Be the first to like this

No Downloads
Views
Total Views
2,648
On Slideshare
0
From Embeds
0
Number of Embeds
1
Actions
Shares
0
Downloads
10
Comments
0
Likes
0
Embeds 0
No embeds

Report content
Flagged as inappropriate Flag as inappropriate
Flag as inappropriate

Select your reason for flagging this presentation as inappropriate.

Cancel
No notes for slide

Transcript

  • 1. Speed up your development environmentPHP + Nginx + Fedora + PG Marcus Sá Developer | Woompa marcus.m.sa@gmail.com @sa_vini
  • 2. Scenario ● Ruby developer ● PHP is the customers requirement● Development environment not installed ● Very tight deadline (O RLY?)
  • 3. Decisions taken ● Avoid complexity* ● Use PHP to develop● Install environment: PHP PostgreSQL, Nginx , ● Using a CMS (Joomla will take care)
  • 4. Avoid complexity* ● Develop the minimum possible● Use modules and components already made ● Focus on the important things
  • 5. Installing environment ● Update your system ● Install Nginx ● Install PHP ● Install PostgreSQL ● Configure Nginx
  • 6. Update your system $ yum update
  • 7. Install NginxInstalling nginx$ yum install nginxSet it to start on boot$ chkconfig nginx onStart right now!$ service nginx start sudo if needed
  • 8. Configure Nginxserver { server_name www.example.com example.com; root /srv/www/www.example.com/public_html; location / { index index.html index.htm; } location ~ .php$ { include /etc/nginx/fastcgi_params; fastcgi_pass 127.0.0.1:53217; fastcgi_index index.php; fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name; }}
  • 9. Install PHPinstall packages required for PHP-FastCGI$ yum install php spawn-fcgiSet it to start on boot$ chkconfig spawn-fcgi onStart right now!$ service spawn-fcgi start sudo if needed
  • 10. Configure PHPediting spawn-fcgi$ nano /etc/sysconfig/spawn-fcgiFASTCGI_USER=nginxFASTCGI_GROUP=nginxSOCKET=/var/run/spawn-fcgi.sockPIDFILE=/var/run/spawn-fcgi.pidPHP5_SOCKET=/var/run/php-fcgi.sockCHILDREN=6PHP5=/usr/bin/php-cgiMODE=0600OPTIONS="-s $PHP5_SOCKET -S -M $MODE -P $PIDFILE -C $CHILDREN -u $FASTCGI_USER -g $FASTCGI_GROUP-f $PHP5" sudo if needed
  • 11. Install PostgreSQLDownload ithttp://www.enterprisedb.com/Make executable$ chmod +x postgre_file.binExecute and install$ ./postgre_file.bin sudo if needed
  • 12. Thats all folks Thanks!

×