Automate your LAMP stack setup on Linux servers with one click! This script installs and configures Apache, MariaDB, and PHP, making server setup fast, reliable, and reproducible.
β
Auto-detects Linux distribution (Debian/Ubuntu or CentOS/RHEL)
β
Installs & configures Apache/HTTPD
β
Installs & configures MariaDB (MySQL alternative)
β
Creates databases & users with proper privileges
β
Installs PHP with required modules
β
Creates phptest.php to verify PHP setup
β
Automatically starts & enables all services
LAMP/
β
ββ lamp_install.sh # Main installation script
ββ README.md # Project documentation
ββ lamp_install.log # Installation log file
- Linux server (Ubuntu/Debian or CentOS/RHEL)
- Root or sudo privileges
- Internet access for package installation
git clone https://github.com/gauravchile/LAMP.git
cd LAMPchmod +x lamp_script.sh./lamp_script.sh- Apache default page:
http://<server-ip>/ - PHP info page:
http://<server-ip>/phptest.php
π‘ Tip: Replace
<server-ip>with your server's public or private IP address.
- Automating package management with apt, yum, or dnf
- Service management with systemctl
- Database automation using MariaDB SQL scripts
- Writing portable & reusable Bash scripts for Linux
- Extendable for more PHP modules or web services
- Perfect for development environments or quick server setups
- Great hands-on project for Linux sysadmin & DevOps practice