Create a gist now

Instantly share code, notes, and snippets.

Docker Centos 7 + PHP 7 + Phalcon 2.1.x
FROM centos:latest
MAINTAINER Ömer ÜCEL <omerucel@gmail.com>
RUN yum install -y --nogpgcheck epel-release && \
rpm -qa | grep -q remi-release || rpm -Uvh http://rpms.famillecollet.com/enterprise/remi-release-7.rpm && \
yum --enablerepo=remi,remi-php70 install -y --nogpgcheck \
git-core \
nginx \
gcc \
gcc-c++ \
make \
unzip \
libtool \
libgearman \
libgearman-devel \
wget \
php \
php-opcache \
php-apc \
php-devel \
pcre-devel \
php-pear \
php-pecl-xdebug \
php-mysql \
php-pecl-memcached \
php-xml \
php-gd \
php-mbstring \
php-mcrypt \
php-fpm \
php-soap \
php-json \
php-curl && \
TMPDIR=/tmp yum clean metadata && \
TMPDIR=/tmp yum clean all
RUN rm -rf /etc/nginx/conf.d/*.conf && \
curl --silent "http://timkay.com/solo/solo" -o /usr/bin/solo && \
chmod +x /usr/bin/solo && \
cd / && curl -sS https://getcomposer.org/installer | php && \
mv /composer.phar /usr/local/bin/composer
RUN cd / && \
git clone --depth=1 -b 0.16 https://github.com/skvadrik/re2c.git && \
cd /re2c/re2c && ./autogen.sh && ./configure && make && make install && \
cd / && \
rm -rf /re2c
RUN cd / && \
git clone https://github.com/json-c/json-c.git && \
cd /json-c && ./autogen.sh && ./configure && make && make install && \
cd / && rm -rf /json-c
RUN cd / && \
git clone https://github.com/phalcon/zephir && \
cd /zephir && ./install-nosudo
RUN cd / && \
git clone --depth=1 -b 2.1.x https://github.com/phalcon/cphalcon.git && \
cd /cphalcon && \
/zephir/bin/zephir build --backend=ZendEngine3 && \
mv ext/modules/phalcon.so /usr/lib64/php/modules/ && \
echo "extension=phalcon.so" > /etc/php.d/phalcon.ini && \
cd / && \
rm -rf /cphalcon
RUN wget https://github.com/wcgallego/pecl-gearman/archive/master.zip && \
unzip master.zip && \
cd pecl-gearman-master && \
phpize && \
./configure && \
make install && \
echo "extension=gearman.so" > /etc/php.d/gearman.ini
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment