solidus icon indicating copy to clipboard operation
solidus copied to clipboard

Docker demo does not start on M1 macs

Open jeffmagill opened this issue 3 years ago • 1 comments

Attempting to start the docker demo on a clean macOS M1 machine results in the error,

`initialize': Function not implemented - Failed to initialize inotify (Errno::ENOSYS)

The solution offered in docker/for-mac is to provide arm64 images.

Solidus Version:

Not applicable. The version used in the docker image.

To Reproduce

Run the docker command,

docker run --rm -it -p 3000:3000 solidusio/solidus-demo:latest

Current behavior

The command outputs:

% docker run --rm -it -p 3000:3000 solidusio/solidus-demo:latest Unable to find image 'solidusio/solidus-demo:latest' locally latest: Pulling from solidusio/solidus-demo bc9ab73e5b14: Pull complete 193a6306c92a: Pull complete e5c3f8c317dc: Pull complete a587a86c9dcb: Pull complete 72744d0a318b: Pull complete 31d57ef7a684: Pull complete a2a726425592: Pull complete 4f2f2375eda7: Pull complete 85c0c9794ff1: Pull complete fcc022f6df4e: Pull complete 27b98e5a1429: Pull complete c6a03bcf8650: Pull complete 24ab9672b0a0: Pull complete 084b4485679a: Pull complete Digest: sha256:dbf7417d319693ca88ac34f2a89836d9fb88a43127f06d13caa8d92a0f9633fc Status: Downloaded newer image for solidusio/solidus-demo:latest WARNING: The requested image's platform (linux/amd64) does not match the detected host platform (linux/arm64/v8) and no specific platform was requested => Booting Puma => Rails 5.2.2 application starting in development => Run rails server -h for more startup options Exiting Traceback (most recent call last): 80: from bin/rails:4:in <main>' 79: from /usr/local/bundle/gems/activesupport-5.2.2/lib/active_support/dependencies.rb:291:in require' 78: from /usr/local/bundle/gems/activesupport-5.2.2/lib/active_support/dependencies.rb:257:in load_dependency' 77: from /usr/local/bundle/gems/activesupport-5.2.2/lib/active_support/dependencies.rb:291:in block in require' 76: from /usr/local/bundle/gems/bootsnap-1.4.1/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:29:in require' 75: from /usr/local/bundle/gems/bootsnap-1.4.1/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:20:in require_with_bootsnap_lfi' 74: from /usr/local/bundle/gems/bootsnap-1.4.1/lib/bootsnap/load_path_cache/loaded_features_index.rb:83:in register' 73: from /usr/local/bundle/gems/bootsnap-1.4.1/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:21:in block in require_with_bootsnap_lfi' 72: from /usr/local/bundle/gems/bootsnap-1.4.1/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:21:in require' 71: from /usr/local/bundle/gems/railties-5.2.2/lib/rails/commands.rb:18:in

' 70: from /usr/local/bundle/gems/railties-5.2.2/lib/rails/command.rb:46:in invoke' 69: from /usr/local/bundle/gems/railties-5.2.2/lib/rails/command/base.rb:65:in perform' 68: from /usr/local/bundle/gems/thor-0.20.3/lib/thor.rb:387:in dispatch' 67: from /usr/local/bundle/gems/thor-0.20.3/lib/thor/invocation.rb:126:in invoke_command' 66: from /usr/local/bundle/gems/thor-0.20.3/lib/thor/command.rb:27:in run' 65: from /usr/local/bundle/gems/railties-5.2.2/lib/rails/commands/server/server_command.rb:142:in perform' 64: from /usr/local/bundle/gems/railties-5.2.2/lib/rails/commands/server/server_command.rb:142:in tap' 63: from /usr/local/bundle/gems/railties-5.2.2/lib/rails/commands/server/server_command.rb:147:in block in perform' 62: from /usr/local/bundle/gems/railties-5.2.2/lib/rails/commands/server/server_command.rb:51:in start' 61: from /usr/local/bundle/gems/railties-5.2.2/lib/rails/commands/server/server_command.rb:89:in log_to_stdout' 60: from /usr/local/bundle/gems/rack-2.0.6/lib/rack/server.rb:354:in wrapped_app' 59: from /usr/local/bundle/gems/railties-5.2.2/lib/rails/commands/server/server_command.rb:27:in app' 58: from /usr/local/bundle/gems/rack-2.0.6/lib/rack/server.rb:219:in app' 57: from /usr/local/bundle/gems/rack-2.0.6/lib/rack/server.rb:319:in build_app_and_options_from_config' 56: from /usr/local/bundle/gems/rack-2.0.6/lib/rack/builder.rb:40:in parse_file' 55: from /usr/local/bundle/gems/rack-2.0.6/lib/rack/builder.rb:49:in new_from_string' 54: from /usr/local/bundle/gems/rack-2.0.6/lib/rack/builder.rb:49:in eval' 53: from config.ru:in
' 52: from config.ru:in new' 51: from /usr/local/bundle/gems/rack-2.0.6/lib/rack/builder.rb:55:in initialize' 50: from /usr/local/bundle/gems/rack-2.0.6/lib/rack/builder.rb:55:in instance_eval' 49: from config.ru:3:in block in
' 48: from /usr/local/bundle/gems/bootsnap-1.4.1/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:44:in require_relative' 47: from /usr/local/bundle/gems/activesupport-5.2.2/lib/active_support/dependencies.rb:291:in require' 46: from /usr/local/bundle/gems/activesupport-5.2.2/lib/active_support/dependencies.rb:257:in load_dependency' 45: from /usr/local/bundle/gems/activesupport-5.2.2/lib/active_support/dependencies.rb:291:in block in require' 44: from /usr/local/bundle/gems/bootsnap-1.4.1/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:29:in require' 43: from /usr/local/bundle/gems/bootsnap-1.4.1/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:20:in require_with_bootsnap_lfi' 42: from /usr/local/bundle/gems/bootsnap-1.4.1/lib/bootsnap/load_path_cache/loaded_features_index.rb:83:in register' 41: from /usr/local/bundle/gems/bootsnap-1.4.1/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:21:in block in require_with_bootsnap_lfi' 40: from /usr/local/bundle/gems/bootsnap-1.4.1/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:21:in require' 39: from /solidus/sandbox/config/environment.rb:5:in
' 38: from /usr/local/bundle/gems/railties-5.2.2/lib/rails/application.rb:361:in initialize!' 37: from /usr/local/bundle/gems/railties-5.2.2/lib/rails/initializable.rb:60:in run_initializers' 36: from /usr/local/lib/ruby/2.5.0/tsort.rb:205:in tsort_each' 35: from /usr/local/lib/ruby/2.5.0/tsort.rb:226:in tsort_each' 34: from /usr/local/lib/ruby/2.5.0/tsort.rb:347:in each_strongly_connected_component' 33: from /usr/local/lib/ruby/2.5.0/tsort.rb:347:in call' 32: from /usr/local/lib/ruby/2.5.0/tsort.rb:347:in each' 31: from /usr/local/lib/ruby/2.5.0/tsort.rb:349:in block in each_strongly_connected_component' 30: from /usr/local/lib/ruby/2.5.0/tsort.rb:431:in each_strongly_connected_component_from' 29: from /usr/local/lib/ruby/2.5.0/tsort.rb:350:in block (2 levels) in each_strongly_connected_component' 28: from /usr/local/lib/ruby/2.5.0/tsort.rb:228:in block in tsort_each' 27: from /usr/local/bundle/gems/railties-5.2.2/lib/rails/initializable.rb:61:in block in run_initializers' 26: from /usr/local/bundle/gems/railties-5.2.2/lib/rails/initializable.rb:32:in run' 25: from /usr/local/bundle/gems/railties-5.2.2/lib/rails/initializable.rb:32:in instance_exec' 24: from /usr/local/bundle/gems/railties-5.2.2/lib/rails/application/finisher.rb:75:in block in <module:Finisher>' 23: from /usr/local/bundle/gems/activesupport-5.2.2/lib/active_support/lazy_load_hooks.rb:51:in run_load_hooks' 22: from /usr/local/bundle/gems/activesupport-5.2.2/lib/active_support/lazy_load_hooks.rb:51:in each' 21: from /usr/local/bundle/gems/activesupport-5.2.2/lib/active_support/lazy_load_hooks.rb:52:in block in run_load_hooks' 20: from /usr/local/bundle/gems/activesupport-5.2.2/lib/active_support/lazy_load_hooks.rb:67:in execute_hook' 19: from /usr/local/bundle/gems/activesupport-5.2.2/lib/active_support/lazy_load_hooks.rb:62:in with_execution_control' 18: from /usr/local/bundle/gems/activesupport-5.2.2/lib/active_support/lazy_load_hooks.rb:69:in block in execute_hook' 17: from /usr/local/bundle/gems/activesupport-5.2.2/lib/active_support/i18n_railtie.rb:19:in block in class:Railtie' 16: from /usr/local/bundle/gems/activesupport-5.2.2/lib/active_support/i18n_railtie.rb:61:in initialize_i18n' 15: from /usr/local/bundle/gems/activesupport-5.2.2/lib/active_support/i18n_railtie.rb:61:in new' 14: from /usr/local/bundle/gems/activesupport-5.2.2/lib/active_support/evented_file_update_checker.rb:67:in initialize' 13: from /usr/local/bundle/gems/activesupport-5.2.2/lib/active_support/evented_file_update_checker.rb:96:in boot!' 12: from /usr/local/bundle/gems/listen-3.1.5/lib/listen/listener.rb:91:in start' 11: from /usr/local/bundle/gems/listen-3.1.5/lib/listen/fsm.rb:57:in transition' 10: from /usr/local/bundle/gems/listen-3.1.5/lib/listen/fsm.rb:91:in transition_with_callbacks!' 9: from /usr/local/bundle/gems/listen-3.1.5/lib/listen/fsm.rb:121:in call' 8: from /usr/local/bundle/gems/listen-3.1.5/lib/listen/fsm.rb:121:in instance_eval' 7: from /usr/local/bundle/gems/listen-3.1.5/lib/listen/listener.rb:68:in block in class:Listener' 6: from /usr/local/bundle/gems/listen-3.1.5/lib/listen/adapter/base.rb:63:in start' 5: from /usr/local/bundle/gems/listen-3.1.5/lib/listen/adapter/base.rb:40:in configure' 4: from /usr/local/bundle/gems/listen-3.1.5/lib/listen/adapter/base.rb:40:in each' 3: from /usr/local/bundle/gems/listen-3.1.5/lib/listen/adapter/base.rb:45:in block in configure' 2: from /usr/local/bundle/gems/listen-3.1.5/lib/listen/adapter/linux.rb:31:in _configure' 1: from /usr/local/bundle/gems/listen-3.1.5/lib/listen/adapter/linux.rb:31:in new' /usr/local/bundle/gems/rb-inotify-0.10.0/lib/rb-inotify/notifier.rb:63:in `initialize': Function not implemented - Failed to initialize inotify (Errno::ENOSYS)

Expected behavior

The docker container starts properly and the solidus demo is accessible at http://localhost:3000/.

Screenshots

Not applicable.

Desktop (please complete the following information):

  • Chip: Apple M1 Max
  • OS: macOS 12.5.1
  • Browser: Not applicable
  • Version: Not applicable

Additional context

Not applicable

jeffmagill avatar Sep 20 '22 13:09 jeffmagill

Thanks for your report, @jeffmagill. We decided not to maintain the docker image anymore, as it's a maintenance burden for the team that gives very little value.

If you want to check how a default Solidus installation visualization looks, you can check the demo site. Also, notice that the development environment is dockerized. You only need to clone, run docker-compose up -d, and spin up the rails server with docker-compose exec app bin/rails server --binding 0.0.0.0.

I'm sorry you had to find the issue, though. Let me know if you need anything else.

waiting-for-dev avatar Sep 21 '22 03:09 waiting-for-dev