File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -106,20 +106,21 @@ RUN if [ ${INSTALL_MONGO} = true ]; then \
106106 ;fi
107107
108108# ##########################################################################
109- # YAML: extension
109+ # YAML: extension
110110# ##########################################################################
111111
112112ARG INSTALL_YAML=false
113-
113+
114114RUN if [ ${INSTALL_YAML} = true ]; then \
115- apt-get install libyaml-dev -y ; \
116- if [ $(php -r "echo PHP_MAJOR_VERSION;" ) = "5" ]; then \
117- pecl install -a yaml-1.3.2; \
118- else \
119- pecl install yaml; \
120- fi && \
121- echo "extension=yaml.so" >> /etc/php/${LARADOCK_PHP_VERSION}/mods-available/yaml.ini && \
122- ln -s /etc/php/${LARADOCK_PHP_VERSION}/mods-available/yaml.ini /etc/php/${LARADOCK_PHP_VERSION}/cli/conf.d/35-yaml.ini \
115+ apk --update add -U --no-cache --virtual temp yaml-dev \
116+ && apk add --no-cache yaml \
117+ && docker-php-source extract \
118+ && pecl channel-update pecl.php.net \
119+ && pecl install yaml \
120+ && docker-php-ext-enable yaml \
121+ && pecl clear-cache \
122+ && docker-php-source delete \
123+ && apk del temp \
123124;fi
124125
125126
You can’t perform that action at this time.
0 commit comments