Skip to content

Commit ccaec38

Browse files
feat: 增加 php5.4 5.5 7.0 7.1 7.2 7.3 7.4 8.0 8.1 版本 (#69)
1 parent fd8daa9 commit ccaec38

File tree

239 files changed

+79369
-5
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

239 files changed

+79369
-5
lines changed

apps/list.json

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -292,7 +292,7 @@
292292
"key": "php5",
293293
"name": "PHP 5",
294294
"tags": ["Runtime"],
295-
"versions": ["5.6.40"],
295+
"versions": ["5.4.45","5.5.38","5.6.40"],
296296
"shortDescZh": "PHP5 运行环境",
297297
"shortDescEn": "PHP5 Runtime",
298298
"type": "php",
@@ -307,7 +307,7 @@
307307
"key": "php7",
308308
"name": "PHP 7",
309309
"tags": ["Runtime"],
310-
"versions": ["7.4.33"],
310+
"versions": ["7.0.33","7.1.33","7.2.34","7.3.33","7.4.33"],
311311
"shortDescZh": "PHP7 运行环境",
312312
"shortDescEn": "PHP7 Runtime",
313313
"type": "php",
@@ -322,7 +322,7 @@
322322
"key": "php8",
323323
"name": "PHP 8",
324324
"tags": ["Runtime"],
325-
"versions": ["8.2.0"],
325+
"versions": ["8.0.28","8.1.18","8.2.5"],
326326
"shortDescZh": "PHP8 运行环境",
327327
"shortDescEn": "PHP8 Runtime",
328328
"type": "php",

apps/php5/versions/5.4.45/build/.env

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
CONTAINER_PACKAGE_URL=mirrors.ustc.edu.cn
2+
3+
PHP_VERSION=5.4.45
4+
PHP_PHP_CONF_FILE=./php/php.ini
5+
PHP_FPM_CONF_FILE=./php/php-fpm.conf
6+
PHP_LOG_DIR=./logs/php
7+
PHP_EXTENSIONS=
8+
9+
SOURCE_DIR=./www
10+
11+
TZ=Asia/Shanghai
12+
DATA_DIR=./data
13+
IMAGE_NAME=1panel-php:5.4.45

apps/php8/versions/8.2.0/build/config.json renamed to apps/php5/versions/5.4.45/build/config.json

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -113,6 +113,10 @@
113113
{
114114
"label": "curl",
115115
"value": "curl"
116+
},
117+
{
118+
"label": "sg11",
119+
"value": "sourceguardian"
116120
}
117121
],
118122
"envKey": "PHP_EXTENSIONS",
Lines changed: 41 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,41 @@
1+
ARG PHP_IMAGE
2+
FROM ${PHP_IMAGE}
3+
4+
ARG TZ
5+
ARG PHP_EXTENSIONS
6+
ARG CONTAINER_PACKAGE_URL
7+
8+
9+
RUN if [ $CONTAINER_PACKAGE_URL ] ; then sed -i "s/dl-cdn.alpinelinux.org/${CONTAINER_PACKAGE_URL}/g" /etc/apk/repositories ; fi
10+
11+
12+
COPY ./extensions /tmp/extensions
13+
WORKDIR /tmp/extensions
14+
RUN chmod +x install.sh \
15+
&& sh install.sh
16+
17+
ADD ./extensions/install-php-extensions /usr/local/bin/
18+
19+
RUN chmod uga+x /usr/local/bin/install-php-extensions
20+
21+
RUN apk --no-cache add tzdata \
22+
&& cp "/usr/share/zoneinfo/$TZ" /etc/localtime \
23+
&& echo "$TZ" > /etc/timezone
24+
25+
26+
# Fix: https://github.com/docker-library/php/issues/1121
27+
RUN apk add --no-cache --repository http://${CONTAINER_PACKAGE_URL}/alpine/v3.13/community/ gnu-libiconv=1.15-r3
28+
ENV LD_PRELOAD /usr/lib/preloadable_libiconv.so php
29+
30+
31+
# Install composer and change it's cache home
32+
RUN chmod +x install-composer.sh \
33+
&& sh install-composer.sh \
34+
&& rm -rf /tmp/extensions
35+
ENV COMPOSER_HOME=/tmp/composer
36+
37+
# php image's www-data user uid & gid are 82, change them to 1000 (primary user)
38+
RUN apk --no-cache add shadow && usermod -u 1000 www-data && groupmod -g 1000 www-data
39+
40+
41+
WORKDIR /www

0 commit comments

Comments
 (0)