Skip to content

Commit

Permalink
Refactor Docker file layouts
Browse files Browse the repository at this point in the history
  • Loading branch information
ircmaxell committed Apr 18, 2019
1 parent f7a651f commit 6dcbbf4
Show file tree
Hide file tree
Showing 2 changed files with 19 additions and 23 deletions.
19 changes: 7 additions & 12 deletions Docker/dev/ubuntu-16.04/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@ RUN mkdir compiler && \
apt-get update && \
apt-get -y install git build-essential gdb llvm-4.0-dev clang-4.0 unzip curl libcurl4-openssl-dev autoconf libssl-dev libgd-dev libzip-dev bison re2c libxml2-dev libsqlite3-dev libonig-dev vim clang


RUN curl -sL https://deb.nodesource.com/setup_10.x | bash - && \
apt-get -y install nodejs

Expand All @@ -17,23 +16,19 @@ RUN ./buildconf && \
make -j16 && \
make install

WORKDIR ../

RUN curl --silent --show-error https://getcomposer.org/installer | php
RUN mv composer.phar /usr/local/bin/composer

ENV PHP="/usr/local/bin/php", PHP_7_4="/usr/local/bin/php", PHP_CS_FIXER_IGNORE_ENV="true"

COPY php.ini /usr/local/lib/php.ini

WORKDIR php-ast

WORKDIR ../php-ast
RUN git clone https://github.com/nikic/php-ast . && \
phpize && \
./configure && \
make && \
make install

COPY php.ini /usr/local/lib/php.ini

RUN curl --silent --show-error https://getcomposer.org/installer | php -- --no-ansi --install-dir=/usr/local/bin --filename=composer

WORKDIR ../compiler

ENV PHP="/usr/local/bin/php", PHP_7_4="/usr/local/bin/php", PHP_CS_FIXER_IGNORE_ENV="true", COMPOSER_ALLOW_SUPERUSER="1"

CMD ["/bin/bash"]
23 changes: 12 additions & 11 deletions Docker/dev/ubuntu-18.04/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,9 @@ RUN mkdir compiler && \
apt-get update && \
apt-get -y install git build-essential gdb llvm-4.0-dev clang-4.0 unzip curl libcurl4-openssl-dev autoconf libssl-dev libgd-dev libzip-dev bison re2c libxml2-dev libsqlite3-dev libonig-dev vim clang nodejs

RUN curl -sL https://deb.nodesource.com/setup_10.x | bash - && \
apt-get -y install nodejs

RUN curl -L https://github.com/php/php-src/archive/PHP-7.4.zip -o PHP-7.4.zip && unzip PHP-7.4.zip && mv php-src-PHP-7.4 php

WORKDIR php
Expand All @@ -13,21 +16,19 @@ RUN ./buildconf && \
make -j16 && \
make install

WORKDIR ../

RUN curl --silent --show-error https://getcomposer.org/installer | php

ENV PHP="/usr/local/bin/php", PHP_7_4="/usr/local/bin/php", PHP_CS_FIXER_IGNORE_ENV="true"
WORKDIR ../php-ast
RUN git clone https://github.com/nikic/php-ast . && \
phpize && \
./configure && \
make && \
make install

COPY php.ini /usr/local/lib/php.ini

WORKDIR php-ast
RUN git clone https://github.com/nikic/php-ast .
RUN phpize
RUN ./configure
RUN make
RUN make install
RUN curl --silent --show-error https://getcomposer.org/installer | php -- --no-ansi --install-dir=/usr/local/bin --filename=composer

WORKDIR ../compiler

ENV PHP="/usr/local/bin/php", PHP_7_4="/usr/local/bin/php", PHP_CS_FIXER_IGNORE_ENV="true", COMPOSER_ALLOW_SUPERUSER="1"

CMD ["/bin/bash"]

0 comments on commit 6dcbbf4

Please sign in to comment.