Setting up docker on Mac OS – php-intl cannot be installed

I have the following problem:

I want set up a development environment on my Mac using docker and boot2docker.

  • How to pass the result of a command to docker inspect format (Golang template)?
  • ASP.NET on Docker Not Serving Web App to Browser
  • client is newer than server (client API version: 1.24, server API version: 1.21)
  • error during connect: … http: server gave HTTP response to HTTPS client on any docker command with remote host
  • Non-root user in Docker
  • Organization of pods in cluster in Google Container Engine
  • For that I created an image using the below Dockerfile.

    The Problem is, that my php-intl-Extension cannot be installed.. I tried various method. For example to enable it in php.ini via:

    None of the methods will work. Here is the content of my Dockerfile:

    FROM php:5.5-apache
    # use own php.ini file
    COPY config/php.ini /usr/local/etc/php/
    # get some php-extensions
    RUN apt-get update && apt-get install -y \
            libfreetype6-dev \
            libjpeg62-turbo-dev \
            libmcrypt-dev \
            libpng12-dev \
            libicu52 \
            libicu-dev \
            zlib1g-dev \
        && docker-php-ext-install -j$(nproc) iconv mcrypt \
        && docker-php-ext-configure gd --with-freetype-dir=/usr/include/ --with-jpeg-dir=/usr/include/ \
        && docker-php-ext-install -j$(nproc) gd
    RUN apt-get update && apt-get install -y libmemcached-dev \
        && pecl install memcached \
        && docker-php-ext-enable memcached
    # Install intl (not working yet):
    RUN pecl install intl
    # use own src file
    COPY src/ /var/www/html/

    Can anyone help? That would be so great, because this problem takes a lot of time by now. Thanks in advance!!!

  • Mounted docker.sock login not stored
  • Can I call rs.initiate() and rs.Add() from node.js using the MongoDb driver?
  • Node webservice in Docker with entrypoint fails but works otherwise
  • Docker Swarm CD/CI (Jenkins, Docker)
  • How to bind the VM docker-machine creates to OSX IP address?
  • How to log docker build installation package errors
  • One Solution collect form web for “Setting up docker on Mac OS – php-intl cannot be installed”

    You don’t need to use PECL, why don’t you just use:

    docker-php-ext-install intl

    Generally you also need to apt-get install libicu-dev for dependencies, but you already have that.

    Docker will be the best open platform for developers and sysadmins to build, ship, and run distributed applications.