Skip to content

Commit 848d989

Browse files
authored
Merge pull request #38 from elecena/add/yaml
Add yaml extension
2 parents 49e9618 + 9f3788b commit 848d989

File tree

2 files changed

+13
-4
lines changed

2 files changed

+13
-4
lines changed

Dockerfile

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,8 @@ RUN apk add \
2121
libsodium-dev \
2222
libxml2-dev \
2323
libxslt-dev \
24-
linux-headers
24+
linux-headers \
25+
yaml-dev
2526

2627
# fixes "sockets" compilation issues
2728
# sendrecvmsg.c:128:19: error: invalid application of 'sizeof' to incomplete type 'struct cmsgcred'
@@ -43,6 +44,13 @@ RUN docker-php-ext-install \
4344
sysvshm \
4445
xsl
4546

47+
# install yaml extensions from PECL
48+
# https://pecl.php.net/package/yaml/2.2.3
49+
RUN apk add --virtual build-deps autoconf gcc make g++ zlib-dev \
50+
&& pecl channel-update pecl.php.net \
51+
&& pecl install yaml-2.2.3 && docker-php-ext-enable yaml \
52+
&& apk del build-deps
53+
4654
RUN which php; php -v; php -m; php -i | grep ini
4755

4856
#

README.md

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,12 @@
11
python-php
22
==========
33

4-
Python and PHP under the same roof (in **around 100 MB Docker image**).
4+
Python and PHP under the same roof (in **under 125 MB Docker image**).
55

66
https://github.com/elecena/python-php/pkgs/container/python-php
77

88
```
9-
docker pull ghcr.io/elecena/python-php:3.11.2-8.2.3
9+
docker pull ghcr.io/elecena/python-php:3.11.2-8.2.3:v2
1010
```
1111

1212
```
@@ -22,7 +22,7 @@ $ docker run -it elecena/python-php sh info.sh
2222
2323
### Python
2424
Python 3.11.2
25-
virtualenv 20.20.0 from /usr/local/lib/python3.11/site-packages/virtualenv/__init__.py
25+
virtualenv 20.21.0 from /usr/local/lib/python3.11/site-packages/virtualenv/__init__.py
2626
2727
### PHP
2828
PHP 8.2.3 (cli) (built: Feb 14 2023 20:48:45) (NTS)
@@ -74,6 +74,7 @@ xml
7474
xmlreader
7575
xmlwriter
7676
xsl
77+
yaml
7778
Zend OPcache
7879
zlib
7980

0 commit comments

Comments
 (0)