Skip to content

能否新增支持下arm64v8的docker镜像 #3146

Answered by deminy
ha-ni-cc asked this question in Q&A
Discussion options

You must be logged in to vote

You can use image phpswoole/swoole with Hyperf. This image supports multiple architectures, including linux/amd64, linux/arm/v6, linux/arm/v7, linux/arm64/v8, and linux/ppc64le.

Here is an example to create a Hyperf image:

FROM phpswoole/swoole:4.6.1-php7.4-alpine

ARG timezone
ARG APP_ENV=local
ARG APP_NAME=demo

ENV TIMEZONE=${timezone:-"America/Los_Angeles"} \
    APP_ENV=$APP_ENV \
    APP_NAME=$APP_NAME \
    SCAN_CACHEABLE=(true)

COPY . /var/www

RUN set -ex \
    && docker-php-ext-configure pdo_mysql --with-pdo-mysql=mysqlnd \
    && docker-php-ext-install pdo_mysql                            \
    && ln -sf /usr/share/zoneinfo/${TIMEZONE} /etc/localtime \
    && echo "${TIMEZONE}"

Replies: 3 comments 1 reply

Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
1 reply
@koala9527
Comment options

Comment options

You must be logged in to vote
0 replies
Answer selected by limingxinleo
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
4 participants
Converted from issue

This discussion was converted from issue #3145 on January 16, 2021 03:28.