0

Is it possible run docker container with redis:2.8 on macOS with M1? docker log

Setup:

  • macOS M1
  • docker-compose.yml with redis 2.8
version: '2'

services:
  redis:
    image: redis:2.8
    ports:
      - "6379:6379"

In another way through

docker-compose up redis

I got this error

ray_otto
  • 33
  • 8
  • Yeah, it probably is. If you share some more information on what you have done to try and run it you may get more responses. At a minimum, share the command you are using to try and run the docker container and a full logging transcript from that command. – JohnXF Aug 31 '22 at 17:00
  • Please clarify your specific problem or provide additional details to highlight exactly what you need. As it's currently written, it's hard to tell exactly what you're asking. – Community Sep 01 '22 at 04:01
  • @JohnXF I improved me question – ray_otto Sep 05 '22 at 08:59
  • to reach the widest audience - specially on cross-platform tools like docker - try and stick to executing things via commands at a command prompt. For example, on my Windows machine if I create a ``compose.yml`` file containing the definition you have above then I can execute the command like ``docker-compose -f .\compose.yml up`` and redis starts up for me. If that works for you too then obviously 'run container through button on top right corner' is not quite the same thing. – JohnXF Sep 05 '22 at 09:40
  • @JohnXF I added result of `docker-compose up redis` to question description – ray_otto Sep 05 '22 at 14:35
  • If you google the error you are getting ``runtime: failed to create new OS thread (have 2 already; errno=22)`` you will see a hit on a stackoverflow question - https://stackoverflow.com/questions/66349391/failed-to-create-new-os-thread-have-2-already-errno-22 - that looks to provide the answer. Your platform of your M1 mac is not compatible with that specific image you are using so you need to find an image that will work on your M1 Mac. – JohnXF Sep 05 '22 at 14:46
  • @JohnXF ok, I got it. Thank you for help. You can provide your comment as answer and I will accept it as right one if you wish – ray_otto Sep 06 '22 at 14:44
  • redis 2.8 is 9 years old. – hobbs Sep 06 '22 at 18:03

1 Answers1

0

If you google the error you are getting runtime ...

failed to create new OS thread (have 2 already; errno=22)

you will see a hit on another StackOverflow question Failed to create new OS thread (have 2 already; errno=22). That looks to provide the answer - the platform of your M1 Mmac is not compatible with that specific image you are using so you need to find an image that will work on your M1 Mac.

JohnXF
  • 972
  • 9
  • 22