apt install php8.3-fpm php8.3-mysql php8.3-mbstring php8.3-curl php8.3-xml php8.3-imagick php8.3-zip php8.3-gd php8.3-intl php8.3-bcmath
对于Laravel 需要安装 apt install php8.3-bcmath
要把 php8.3-dom 换成 php8.3-xml
说明:需要通过sury源来安装
https://packages.sury.org/php/README.txt
#!/bin/sh# To add this repository please do:
if [ "$(whoami)" != "root" ]; then SUDO=sudofi
${SUDO} apt-get update${SUDO} apt-get -y install lsb-release ca-certificates curl${SUDO} curl -sSLo /tmp/debsuryorg-archive-keyring.deb https://packages.sury.org/debsuryorg-archive-keyring.deb${SUDO} dpkg -i /tmp/debsuryorg-archive-keyring.deb${SUDO} sh -c 'echo "deb [signed-by=/usr/share/keyrings/deb.sury.org-php.gpg] https://packages.sury.org/php/ $(lsb_release -sc) main" > /etc/apt/sources.list.d/php.list'${SUDO} apt-get update
或:
apt install apt-transport-httpscurl -sSLo /usr/share/keyrings/deb.sury.org-php.gpg https://packages.sury.org/php/apt.gpgsh -c 'echo "deb [signed-by=/usr/share/keyrings/deb.sury.org-php.gpg] https://packages.sury.org/php/ $(lsb_release -sc) main" > /etc/apt/sources.list.d/php.list'apt update
https://wiki.crowncloud.net/?How_to_Install_PHP_8_3_on_Debian_11