Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save babarinde/10501a58e4ecbe7e0a6a386678c47043 to your computer and use it in GitHub Desktop.
Save babarinde/10501a58e4ecbe7e0a6a386678c47043 to your computer and use it in GitHub Desktop.
Swoole dev docker file
FROM phpswoole/swoole:4.6.6-php8.0-dev
ENV DISABLE_DEFAULT_SERVER=1
RUN apt-get update
#for mongodb driver
RUN apt-get install -y openssl libcurl4-openssl-dev pkg-config libssl-dev libboost-all-dev
RUN pecl install mongodb \
&& pecl install inotify \
&& docker-php-ext-enable mongodb
# && docker-php-ext-enable inotify
RUN apt-get install -y git
RUN git clone -b v0.3.7 https://github.com/swoole/yasd && cd yasd && phpize --clean && \
phpize && \
./configure && \
make clean && \
make && \
make install
RUN echo "zend_extension=yasd" >> /usr/local/etc/php/conf.d/docker-php-ext-yasd.ini \
&& echo "yasd.debug_mode=remote" >> /usr/local/etc/php/conf.d/docker-php-ext-yasd.ini \
&& echo "yasd.remote_host=172.17.0.1" >> /usr/local/etc/php/conf.d/docker-php-ext-yasd.ini \
&& echo "yasd.remote_port=9000" >> /usr/local/etc/php/conf.d/docker-php-ext-yasd.ini \
&& echo "yasd.log_level=0" >> /usr/local/etc/php/conf.d/docker-php-ext-yasd.ini \
&& echo "yasd.breakpoints_file=yasd.log" >> /usr/local/etc/php/conf.d/docker-php-ext-yasd.ini
# COPY etc/supervisor/available.d/* /etc/supervisor/available.d/
# COPY usr/local/boot/* /usr/local/boot
RUN docker-php-ext-enable inotify
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment