国产+高潮+在线,国产 av 仑乱内谢,www国产亚洲精品久久,51国产偷自视频区视频,成人午夜精品网站在线观看

使用docker運行創(chuàng)建webman后,運行php start.php start 報錯

oceansu

使用docker運行創(chuàng)建webman后,運行php start.php start 報錯

程序代碼

# 最小鏡像
FROM php:8.3.14-cli-alpine
LABEL MAINTAINER="oceansu"
# 設置鏡像源(科大)并且更新
# 設置為調(diào)試模式
RUN set -x && \
        sed -i 's/dl-cdn.alpinelinux.org/mirrors.ustc.edu.cn/g' /etc/apk/repositories && \
        apk update && \
        apk upgrade
# 設置時區(qū)
RUN apk add --no-cache tzdata && \ 
        cp /usr/share/zoneinfo/Asia/Shanghai /etc/localtime && \
    # 設置為上海時區(qū)
        echo "Asia/Shanghai" > /etc/timezone && \
    # 查看時區(qū)
        date -R
# 下載必要的包(--no-cache下載完成后清除緩存,在容器內(nèi)是很有必要的)
# 找不到去alpine-linux package查找
RUN apk add --no-cache \
        bash \
        curl \
        zip \
        unzip
# 本地下載安裝器
COPY ./install-php-extensions /usr/local/bin/install-php-extensions
# 安裝擴展安裝器
RUN chmod +x /usr/local/bin/install-php-extensions && \
    install-php-extensions pcntl posix
# 安裝composer(使用阿里云鏡像)
RUN curl https://mirrors.aliyun.com/composer/composer.phar -o composer.phar && \
        chmod +x composer.phar && \
        mv composer.phar /usr/local/bin/composer && \
    # 換源
        composer config -g repo.packagist composer https://mirrors.aliyun.com/composer/ && \
        mkdir www && cd www/
# 設置主目錄
WORKDIR /www
# 暴露端口
EXPOSE 8787
# 必須加上"/bin/sh", "-l", "-c" Docker 運行的默認 shell 不是登錄 shell,這意味著 /etc/profile.d/ 中的腳本不會被處理。
# ENTRYPOINT ["/bin/sh", "-l", "-c","php start.php start"]
CMD [ "/bin/sh" ]

之后執(zhí)行

composer create-project workerman/webman
cd ./webman && php start.php start

報錯信息

Fatal error: Declaration of Webman\Http\Request::file($name = null) must be compatible with Workerman\Protocols\Http\Request::file(?string $name = null): mixed in /www/webman/vendor/workerman/webman-framework/src/Http/Request.php on line 119
Worker[520] process terminated with ERROR: E_COMPILE_ERROR "Declaration of Webman\Http\Request::file($name = null) must be compatible with Workerman\Protocols\Http\Request::file(?string $name = null): mixed in /www/webman/vendor/workerman/webman-framework/src/Http/Request.php on line 119"
587 1 0
1個回答

walkor 打賞

composer代理有問題,把composer代理刪了,重新安裝

??