Saleor-Storefront 未出现在 localhost:3000。看起来店面端口未绑定到端口 3000

Saleor-Storefront does not show up on localhost:3000. Looks like storefront port is not bound to port 3000

在 MacOS 中,我无法访问 localhost:3000 上的销售或店面。执行安装步骤后我没有看到任何错误,但店面容器未绑定到端口 3000。 这些是我当前签出的 saleor-platform 分支机构: enter image description here

这是容器设置的样子。请注意,saleor-platform-storefront-1 没有绑定到 3000 的端口: enter image description here

这是 docker-compose.yml 文件在 saleor-platform 文件夹中的样子: enter image description here

这是编译成功后控制台输出的样子: enter image description here

现在,如果我用以下内容更新 docker-compose.yml 文件,URL localhost:3000 可以访问,但会出错: enter image description here

我收到以下错误: enter image description here

试试这个。更改 docker-compose.yml 文件。

  storefront:
    build:
      context: ./saleor-storefront
      dockerfile: ./Dockerfile.dev
    ports:
      - 3000:3000
    restart: unless-stopped
    #network_mode: "host"
    volumes:
      - ./saleor-storefront/:/app:cached
      - /app/node_modules/
    command: npm start -- --host 0.0.0.0
    #env_file: common.env