https://github.com/Tinywan/docker-php-webman
[]()
[]()
[]()
[]()
docker build -t tinywan/docker-php-webman:8.3.4 .
Start the Docker container:
docker run --rm -it -p 8787:8787 -v /home/www/webman:/app tinywan/docker-php-webman
docker run --rm -it -p 8787:8787 -v e:/dnmp/www/webman:/app tinywan/docker-php-webman
Test Run
PHP Version 8.1.4
status
bash-5.1# php -m
[PHP Modules]
bcmath
bz2
calendar
Core
ctype
curl
date
dom
event
fileinfo
filter
ftp
gd
hash
iconv
json
libxml
mbstring
mysqli
mysqlnd
openssl
pcntl
pcre
PDO
pdo_mysql
pdo_sqlite
Phar
posix
readline
redis
Reflection
session
SimpleXML
soap
sockets
sodium
SPL
sqlite3
standard
tokenizer
xml
xmlreader
xmlwriter
Zend OPcache
zip
zlib
[Zend Modules]
Zend OPcache
delete all container
docker rm `docker ps -a -q`
delete all images
docker rmi -f $(docker images -qa)
=> ERROR [ 7/14] RUN chmod +x install.sh && sh install.sh && rm -rf /tmp/extension 0.2s
------
> [ 7/14] RUN chmod +x install.sh && sh install.sh && rm -rf /tmp/extension:
: not foundll.sh: line 1: #!/bin/sh
: not foundll.sh: line 2:
: not foundll.sh: line 4:
: not foundll.sh: line 10: echo
: not foundll.sh: line 11:
: not foundll.sh: line 13:
: not foundll.sh: line 30:
0.217 install.sh: return: line 36: Illegal number: 0
查看文本格式
$ cat -A install.sh
M-oM-;M-?#!/bin/sh^M$
^M$
執(zhí)行轉(zhuǎn)換
# 安裝 sudo apt-get install dos2unix
dos2unix install.sh
基于這個會環(huán)境我在docker build 時候 dockerfile中的composer install 執(zhí)行成功,容器里確沒生成對應(yīng)的 vendor目錄,請問這種情況是哪里出現(xiàn)了問題?我應(yīng)該從那個方向去查找?
dockerfile 如下:
FROM tinywan/docker-php-webman:7.4.29
WORKDIR /app/
COPY . /app/
RUN composer install && composer dump-autoload -o \
&& composer clearcache
docker中部署workerman服務(wù)的話,需要在docker中做官方推薦的linux內(nèi)核調(diào)優(yōu)嗎?還是只在docker宿主機中作內(nèi)核參數(shù)調(diào)優(yōu)就行了
http://m.wtbis.cn/doc/workerman/appendices/kernel-optimization.html 官方有出內(nèi)核調(diào)優(yōu)文檔
感謝分享