LCMP 一键安装脚本

LCMP

LCMP 一键安装脚本是一个用 Bash Shell 编写的,安装 LCMP (Linux + Caddy + MariaDB + PHP) 生产环境的 Shell 脚本。
本脚本全部采用 rpm 或 deb 包(二进制)安装的方式来安装 LCMP 环境。

Caddy 由 Teddysun Repository 提供。
MariaDB 由 MariaDB Repository 提供。
PHP 的 rpm 由 Remi Repository 提供,deb 由 deb.sury.org 提供。

你可以在执行完本脚本后继续使用 dnfapt-get 命令直接安装各种插件。

支持的 PHP 插件:php-pecl-mongodb2,php-pecl-grpc,php-pecl-zip,php-pecl-yac,php-pecl-protobuf,php-pecl-yaml 等。更多详情见此处

系统需求

硬盘空间: 5 GiB
内存空间: 512 MiB
连接互联网
使用 root 用户

支持软件列表

Caddy 2
MariaDB 10.11, 11.4, 11.8
PHP 7.4, 8.0, 8.1, 8.2, 8.3, 8.4, 8.5

支持系统架构

x86_64 (amd64)
aarch64 (arm64)

适用系统

Enterprise Linux 8 (RHEL 8, Rocky Linux 8, AlmaLinux 8, Oracle Linux 8)
Enterprise Linux 9 (CentOS Stream 9, RHEL 9, Rocky Linux 9, AlmaLinux 9, Oracle Linux 9)
Enterprise Linux 10 (CentOS Stream 10, RHEL 10, Rocky Linux 10, AlmaLinux 10, Oracle Linux 10)
Debian 11
Debian 12
Debian 13
Ubuntu 20.04
Ubuntu 22.04
Ubuntu 24.04

如何安装

在 Enterprise Linux 8 / 9 / 10 系统

dnf -y install wget git
git clone https://github.com/teddysun/lcmp.git
cd lcmp
chmod 755 *.sh
./lcmp.sh 2>&1 | tee lcmp.log

在 Debian 11 ~ 13 / Ubuntu 20.04 ~ 24.04 系统

apt-get -y install wget git
git clone https://github.com/teddysun/lcmp.git
cd lcmp
chmod 755 *.sh
./lcmp.sh 2>&1 | tee lcmp.log

更多用法,请参考链接:
https://github.com/teddysun/lcmp

LAMP 一键安装脚本(2024 年新版)

LAMP

LAMP 一键安装脚本(2024 年新版)是一个用 Bash Shell 编写的,安装 LAMP (Linux + Apache + MariaDB + PHP) 生产环境的 Shell 脚本。
本脚本不再使用编译安装,而是全部采用 rpm 或 deb 包(二进制)安装的方式来安装 LAMP 环境。

Apache 由 Teddysun Repository 提供。
MariaDB 由 MariaDB Repository 提供。
PHP 由 Remi Repository 提供。

你甚至可以在执行完本脚本后继续使用 yum 或 dnf 命令直接安装各种插件。
比如 Apache 插件:mod_jk,mod_cluster,mod_security,mod_perl,python3-mod_wsgi 等。

dnf install -y 插件名

Apache 支持的额外插件列表:

mod_auth_cas
mod_auth_gssapi
mod_auth_mellon
mod_authnz_external
mod_authnz_jwt
mod_authnz_pam
mod_auth_openidc
mod_authz_unixgroup
mod_bw
mod_cluster
mod_dav_svn
mod_fcgid
mod_gnutls
mod_h264_streaming
mod_jk
mod_ldap
mod_log_post
mod_maxminddb
mod_md
mod_mono
mod_perl
mod_proxy_cluster
mod_qos
mod_security
mod_security_crs
python3-mod_wsgi

比如 PHP 插件:php-pecl-mongodb,php-pecl-grpc,php-pecl-zip,php-pecl-yac,php-pecl-protobuf,php-pecl-yaml 等。更多详情见此处

系统需求

硬盘空间: 5 GiB
内存空间: 512 MiB
连接互联网
使用 root 用户

支持软件列表

Apache 2.4
MariaDB 10.11, 11.4, 11.8
PHP 7.4, 8.0, 8.1, 8.2, 8.3, 8.4, 8.5

支持系统架构

x86_64 (amd64)
aarch64 (arm64)

适用系统

Enterprise Linux 8 (RHEL 8, Rocky Linux 8, AlmaLinux 8, Oracle Linux 8)
Enterprise Linux 9 (CentOS Stream 9, RHEL 9, Rocky Linux 9, AlmaLinux 9, Oracle Linux 9)
Enterprise Linux 10 (CentOS Stream 10, RHEL 10, Rocky Linux 10, AlmaLinux 10, Oracle Linux 10)

如何安装

dnf -y install wget git
git clone -b rpm https://github.com/teddysun/lamp.git
cd lamp
chmod 755 *.sh
./lamp.sh 2>&1 | tee lamp.log

更多用法,请参考链接:
https://github.com/teddysun/lamp/tree/rpm

适用系统

Debian 11
Debian 12
Debian 13
Ubuntu 20.04
Ubuntu 22.04
Ubuntu 24.04

如何安装

apt-get -y install wget git
git clone -b deb https://github.com/teddysun/lamp.git
cd lamp
chmod 755 *.sh
./lamp.sh 2>&1 | tee lamp.log

更多用法,请参考链接:
https://github.com/teddysun/lamp/tree/deb

LAMP 一键安装脚本是什么?

LAMP

LAMP 一键安装脚本是一个用 Linux Shell 编写的可以为 Amazon Linux 2/CentOS/Debian/Ubuntu 系统的 VPS 或服务器安装 LAMP(Linux + Apache + MySQL/MariaDB + PHP) 生产环境的 Shell 脚本。包含一些可选安装组件如:
Zend OPcache, ionCube Loader, PDFlib, APCu, imagick, libsodium, memcached, redis, mongodb, swoole, yaf, yar, msgpack, psr, phalcon, grpc, xdebug

其他诸如:OpenSSL, ImageMagick, Memcached, phpMyAdmin, Adminer, Redis, re2c, KodExplorer

同时还有一些辅助脚本如:虚拟主机管理、Apache、MySQL/MariaDB、PHP 及 PhpMyAdmin、Adminer 的升级等。

为什么需要LAMP?

手动逐个编译安装各个组件,需要输入各种命令,且有可能会中途出错。
对于想要成功搭建 LAMP 建站环境来说,可以节约大量时间和精力。

LAMP 有什么优点?

LAMP 是最经典的建站环境之一,风靡世界十几年。
而本脚本只需几个简单交互,选择需要安装的包,即可一路安装,无人值守。

本脚本默认支持 PHP 探针所标识的所有 PHP 组件,截图如下:
组件支持

英文版 PHP 探针所标识的所有 PHP 组件,截图如下:
Components

如何获取

通过本站下载页面,你可以使用它在 VPS 或独立服务器上安装。
也可以在安装页面,按照步骤说明直接安装。

致谢
感谢国外主机测评方舟笔记MoonVM丽萨主机Peter Freedom 对本站的支持。
感谢之前对本站捐赠过的朋友们。

广告
丽萨主机