Correct pulling edxops/forums way

Viewed 298

I'm making my own devstack for works with OpenEdx.

I pulled the official devstack repository from edx and i'm modifying it.

I'm trying add forums to my stack but i can't run in since docker compose.

I added this to composer file:

forums:
    command: bash -c 'source /edx/app/forum/cs_comments_service_env && ruby app.rb -p 18080'
    container_name: edx.devstack.forums
    depends_on:
      #   - xqueue:xqueue
      - mongo
      - elasticsearch
      # - rabbitmq:rabbitmq
      - mysql
      - memcached
    environment:
      CACHE_LOCATION: edx.devstack.memcached:12211
      DB_HOST: edx.devstack.mysql
      TEST_ELASTICSEARCH_URL: "http://edx.devstack.elasticsearch:9200"
    image: edxops/forums:latest
    ports:
      - 4567:4567

I'm confuse about wich the correct command in run:

studio:
    command: bash -c 'source /edx/app/edxapp/edxapp_env && python /edx/app/edxapp/edx-platform/manage.py cms runserver 0.0.0.0:18010 --settings devstack_docker'

This is the command for studio.

forums:
    command: bash -c 'source /edx/app/forum/cs_comments_service_env && ruby app.rb -p 18080'

I tried with this but the folder doesn't exist.

So i tried with: command: bash -c 'ruby app.rb -p 18080' but i get this error:

edx.devstack.forums | bash: ruby: command not found
edx.devstack.forums exited with code 127

So, i'm confused about the forums image and about how can i provide it for works correctly.

Can anyone help me? - How provide it? - How run it(command)?

UPDATE:

I have a new configuration:

forums:
    command: bash -c 'cd /edx/app/forum/cs_comments_service && exec /edx/app/forum/cs_comments_service/bin/unicorn -c config/unicorn_tcp.rb'
    container_name: edx.devstack.forums
    depends_on:
      # - xqueue:xqueue
      - mongo
      - elasticsearch
      # - rabbitmq:rabbitmq
      - mysql
      - memcached
    environment:
      CACHE_LOCATION: edx.devstack.memcached:12211
      DB_HOST: edx.devstack.mysql
      SEARCH_SERVER: "http://edx.devstack.elasticsearch:9200"
      TEST_ELASTICSEARCH_URL: "http://edx.devstack.elasticsearch:9200"
      MONGOHQ_URL: "mongodb://cs_comments_service:password@mongo.edx:27017/cs_comments_service"
      GEM_PATH: "/edx/app/forum/.gem"
      GEM_HOME: "/edx/app/forum/.gem"
      RBENV_ROOT: "/edx/app/forum/.rbenv"
    image: edxops/forum:latest
    ports:
      - 4567:4567

But i still have this issue:

docker-compose logs -f --tail=500 | grep edx.devstack.forums
Attaching to edx.devstack.forums, edx.devstack.chrome, edx.devstack.firefox, edx.devstack.credentials, edx.devstack.discovery, edx.devstack.elasticsearch, edx.devstack.ecommerce, edx.devstack.studio, edx.devstack.lms, edx.devstack.memcached, edx.devstack.mysql, edx.devstack.mongo
edx.devstack.forums | /usr/bin/env: ‘ruby’: No such file or directory

But, why?

1 Answers
Related