Dockerfile: Apple Silicon M1 ARM problem
Tried run on Apple Silicon, M1. I have installed latest golang from website go1.16.darwin-arm64.pkg (released few yours ago) but still doesn’t work. Docker try use go 1.8.1. Any ideas?
-> Executing /opt/docker/provision/entrypoint.d/05-permissions.sh
-> Executing /opt/docker/provision/entrypoint.d/10-php-debugger.sh
PHP-Debugger: not specified - default is xdebug
- Removing PHP module blackfire
-> Executing /opt/docker/provision/entrypoint.d/20-nginx-dev.sh
runtime: failed to create new OS thread (have 2 already; errno=22)
fatal error: newosproc
runtime stack:
runtime.throw(0x6430dc, 0x9)
/usr/local/Cellar/go/1.8.1/libexec/src/runtime/panic.go:596 +0x95
runtime.newosproc(0xc420032000, 0xc420042000)
/usr/local/Cellar/go/1.8.1/libexec/src/runtime/os_linux.go:163 +0x18c
runtime.newm(0x650dd0, 0x0)
/usr/local/Cellar/go/1.8.1/libexec/src/runtime/proc.go:1628 +0x137
runtime.main.func1()
/usr/local/Cellar/go/1.8.1/libexec/src/runtime/proc.go:126 +0x36
runtime.systemstack(0x75bb00)
/usr/local/Cellar/go/1.8.1/libexec/src/runtime/asm_amd64.s:327 +0x79
runtime.mstart()
/usr/local/Cellar/go/1.8.1/libexec/src/runtime/proc.go:1132
goroutine 1 [running]:
runtime.systemstack_switch()
/usr/local/Cellar/go/1.8.1/libexec/src/runtime/asm_amd64.s:281 fp=0xc42002e788 sp=0xc42002e780
runtime.main()
/usr/local/Cellar/go/1.8.1/libexec/src/runtime/proc.go:127 +0x6c fp=0xc42002e7e0 sp=0xc42002e788
runtime.goexit()
/usr/local/Cellar/go/1.8.1/libexec/src/runtime/asm_amd64.s:2197 +0x1 fp=0xc42002e7e8 sp=0xc42002e7e0
About this issue
- Original URL
- State: closed
- Created 3 years ago
- Reactions: 11
- Comments: 24 (1 by maintainers)
Thanks @KornelKrupa - works for
webdevops/php-nginx:7.4&webdevops/nginx:alpine.This is the entirety of a working dockerfile as an example for
webdevops/php-nginx:7.4:In my Dockerfile I added:
RUN wget -O "/usr/local/bin/go-replace" "https://github.com/webdevops/goreplace/releases/download/1.1.2/gr-arm64-linux" \ && chmod +x "/usr/local/bin/go-replace" \ && "/usr/local/bin/go-replace" --versionJust wondering if there’s any updates on M1 support or if there’s anything we might be able to help with?
@Pablo-Camara
you can try these, I’ve modified Dockerfiles from webdevops/Dockfile, and now worked on my M1.
https://github.com/Runner668/php-7.4 https://github.com/Runner668/php-apache-7.4 https://github.com/Runner668/php-apache-dev-7.4
Just fixed it be updating gosu and go-replace
@nK2708 could you please show a little more of your Dockerfile ? I was using the image: webdevops/… directly in the docker compose, I’ve tried using a Docker file and adding
FROM webdevops/php-apache…
RUN wget -O “/usr/local/bin/go-replace” “https://github.com/webdevops/goreplace/releases/download/1.1.2/gr-arm64-linux” RUN chmod +x “/usr/local/bin/go-replace” RUN “/usr/local/bin/go-replace” --version
and that does not seem to be enough to get it working, would you be so kind and guide me on how you made it ? @nK2708
Thanks in advance
i got error when add your line
#6 3.775 2021-04-02 04:52:35 (2.61 MB/s) - ‘/usr/local/bin/go-replace’ saved [3671714/3671714] #6 3.775 #6 3.777 --2021-04-02 04:52:35-- http://%20/ #6 3.777 Resolving ( )... failed: Name or service not known. #6 3.777 wget: unable to resolve host address ‘ ’ #6 3.778 FINISHED --2021-04-02 04:52:35-- #6 3.778 Total wall clock time: 2.8s #6 3.778 Downloaded: 1 files, 3.5M in 1.3s (2.61 MB/s)After I separated that line and it worked.
RUN wget -O "/usr/local/bin/go-replace" "https://github.com/webdevops/goreplace/releases/download/1.1.2/gr-arm64-linux"RUN chmod +x "/usr/local/bin/go-replace"RUN "/usr/local/bin/go-replace" --versionTks @KornelKrupa
Does anyone know if there is any plan to support ARM somewhen?
If it’s not on the roadmap that’s okay but I would at least love to know so I can look for alternatives or start writing my own images
@yereth just add image:runner668/php-apache:7.4 (or the other images, like php-apache-dev:7.4) in your compose file.