From 3e0331100c61c22c48edafee05fd89f811ed2a8f Mon Sep 17 00:00:00 2001 From: Cherry Sakura Date: Fri, 27 Oct 2023 02:02:11 +0000 Subject: [PATCH] =?UTF-8?q?=E6=9B=B4=E6=96=B0=20Dockerfile?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- Dockerfile | 27 +++++++++++++++++++++++++++ 1 file changed, 27 insertions(+) create mode 100644 Dockerfile diff --git a/Dockerfile b/Dockerfile new file mode 100644 index 0000000..a0bac96 --- /dev/null +++ b/Dockerfile @@ -0,0 +1,27 @@ +FROM debian:12 + +RUN echo '#!/bin/bash\nphp artisan "$@"' > /usr/bin/art && \ + chmod +x /usr/bin/art + + +RUN echo "deb http://mirrors.tuna.tsinghua.edu.cn/debian/ bullseye main contrib non-free" > /etc/apt/sources.list && \ + echo "deb http://mirrors.tuna.tsinghua.edu.cn/debian/ bullseye-updates main contrib non-free" >> /etc/apt/sources.list && \ + echo "deb http://mirrors.tuna.tsinghua.edu.cn/debian/ bullseye-backports main contrib non-free" >> /etc/apt/sources.list && \ + echo "deb http://mirrors.tuna.tsinghua.edu.cn/debian-security bullseye-security main contrib non-free" >> /etc/apt/sources.list + +RUN apt update +RUN apt install wget lsb-release unzip -y +RUN wget -O /etc/apt/trusted.gpg.d/php.gpg https://packages.sury.org/php/apt.gpg +RUN sh -c 'echo "deb https://packages.sury.org/php/ $(lsb_release -sc) main" > /etc/apt/sources.list.d/php.list' +RUN apt update + +RUN apt install -y php8.2-cli php8.2-bcmath php8.2-bz2 php8.2-curl php8.2-redis php8.2-mongodb php8.2-pgsql php8.2-intl php8.2-mbstring php8.2-zip php8.2-gd php8.2-dom php8.2-mysql php8.2-dev php-pear memcached + +RUN pecl install grpc + +RUN echo "output_buffering = On" >> /etc/php/8.2/cli/php.ini + +RUN wget https://mirrors.aliyun.com/composer/composer.phar -O /usr/bin/composer +RUN chmod +x /usr/bin/composer + +RUN composer config -g repo.packagist composer https://mirrors.aliyun.com/composer/