yarcode / yii2-app-yarcode

Yii2 application template for our projects
Other
26 stars 15 forks source link

memcached support ? #19

Open MixMe opened 6 years ago

MixMe commented 6 years ago

how can i add additional: "apt-get -y install php7.1-memcache memcached" to php-fpm container ?

MixMe commented 6 years ago

I add this:

RUN apk add cyrus-sasl-dev libmemcached-dev \
    && git clone "https://github.com/php-memcached-dev/php-memcached.git" \
    && cd php-memcached \
    && phpize \
    && ./configure --disable-memcached-sasl \
    && make \
    && make install \
&& docker-php-ext-enable memcached

to dockerfile from yiidock/php-fpm folder, but not help. I still get: Error: MemCache requires PHP memcached extension to be loaded.

MixMe commented 6 years ago

Solution: Add on php-fpm/dockerfile and workspace/dockerfile

RUN apk add cyrus-sasl-dev libmemcached-dev \
    && git clone "https://github.com/php-memcached-dev/php-memcached.git" \
    && cd php-memcached \
    && phpize \
    && ./configure --disable-memcached-sasl \
    && make \
    && make install \
&& docker-php-ext-enable memcached

Add on docker-composer:

  memcached:
    image: memcached:alpine
    ports:
      - "11211:11211"
metalagman commented 6 years ago

Please make a pull request.

чт, 14 июн. 2018 г. в 19:04, Maxim Muntean notifications@github.com:

Solution: Add on php-fpm/dockerfile and workspace/dockerfile

RUN apk add cyrus-sasl-dev libmemcached-dev \ && git clone "https://github.com/php-memcached-dev/php-memcached.git" \ && cd php-memcached \ && phpize \ && ./configure --disable-memcached-sasl \ && make \ && make install \ && docker-php-ext-enable memcached

Add on docker-composer:

memcached: image: memcached:alpine ports:

  • "11211:11211"

— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub https://github.com/yarcode/yii2-app-yarcode/issues/19#issuecomment-397270355, or mute the thread https://github.com/notifications/unsubscribe-auth/AB5FNILuoWB8jlcx8gCXX5qsjwyWGstjks5t8lFHgaJpZM4UkCyM .

-- Alexey Samoylov Full Stack Software Engineer +7 (983) 161-90-03 UpWork https://www.upwork.com/freelancers/~01b28c567dba38f89d / LinkedIn https://ru.linkedin.com/in/%D0%B0%D0%BB%D0%B5%D0%BA%D1%81%D0%B5%D0%B9-%D1%81%D0%B0%D0%BC%D0%BE%D0%B9%D0%BB%D0%BE%D0%B2-10469b39/en