Reputation: 27
While trying to run a docker container using docker-compose run
I encountered an error:
runtime: failed to create new OS thread (have 2 already; errno=22) fatal error: newosproc
I have a mac with M1.
I have tried to update (and failed to resolve) the docker file using (source):
FROM --platform=linux/amd64 your_amd64_image
I also tried deleting my docker containers and rebuilding as well as updating docker desktop
.
Upvotes: 0
Views: 668
Reputation: 27
The solution that worked for me that I didn't see posted anywhere on the internet was:
Check docker-compose.yml
for command
and change service
parameter name to entrypoint
:
terminal:
volumes:
- ".:/app"
extends:
file: docker-compose.yml
service: base
command: sh #should be entrypoint
Change to:
terminal:
volumes:
- ".:/app"
extends:
file: docker-compose.yml
entrypoint: base
command: sh #should be entrypoint
Upvotes: 1