Skip to content
This repository was archived by the owner on Aug 1, 2024. It is now read-only.

Commit fac68ae

Browse files
feat: add xqueue-config for ansible-free docker image (#1006)
Co-authored-by: Muhammad Soban Javed <58461728+iamsobanjaved@users.noreply.github.com>
1 parent c44035b commit fac68ae

3 files changed

Lines changed: 44 additions & 5 deletions

File tree

Makefile

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -438,7 +438,7 @@ dev.shell.registrar:
438438
docker-compose exec registrar env TERM=$(TERM) /bin/bash
439439

440440
dev.shell.xqueue:
441-
docker-compose exec xqueue env TERM=$(TERM) /edx/app/xqueue/devstack.sh open
441+
docker-compose exec xqueue env TERM=$(TERM) /bin/bash
442442

443443
dev.shell.lms:
444444
docker-compose exec lms env TERM=$(TERM) bash -c '/bin/bash'
@@ -453,7 +453,7 @@ dev.shell.studio_watcher:
453453
docker-compose exec studio_watcher env TERM=$(TERM) bash -c '/bin/bash'
454454

455455
dev.shell.xqueue_consumer:
456-
docker-compose exec xqueue_consumer env TERM=$(TERM) /edx/app/xqueue/devstack.sh open
456+
docker-compose exec xqueue_consumer env TERM=$(TERM) /bin/bash
457457

458458
dev.shell.analyticsapi:
459459
docker exec -it edx.devstack.analyticsapi env TERM=$(TERM) bash -c '/bin/bash'
@@ -633,4 +633,3 @@ build-courses: ## Build course and provision studio, and ecommerce with it.
633633
$(WINPTY) bash ./course-generator/build-course-json.sh course-generator/tmp-config.json
634634
$(WINPTY) bash ./course-generator/create-courses.sh --studio --ecommerce course-generator/tmp-config.json
635635
rm course-generator/tmp-config.json
636-

configuration_files/xqueue.yml

Lines changed: 34 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,34 @@
1+
CONSUMER_DELAY: 10
2+
CSRF_COOKIE_SECURE: false
3+
DATABASES:
4+
default:
5+
ATOMIC_REQUESTS: true
6+
CONN_MAX_AGE: 0
7+
ENGINE: django.db.backends.mysql
8+
HOST: edx.devstack.mysql57
9+
NAME: xqueue
10+
OPTIONS: {}
11+
PASSWORD: password
12+
PORT: '3306'
13+
USER: xqueue001
14+
LOCAL_LOGLEVEL: INFO
15+
LOGGING_ENV: sandbox
16+
LOG_DIR: /edx/var/logs/xqueue
17+
NEWRELIC_APPNAME: default_env-default_deployment-xqueue
18+
NEWRELIC_LICENSE_KEY: ''
19+
REQUESTS_BASIC_AUTH:
20+
- edx
21+
- edx
22+
SESSION_COOKIE_SECURE: false
23+
SUBMISSION_PROCESSING_DELAY: 1
24+
SYSLOG_SERVER: localhost
25+
UPLOAD_BUCKET: sandbox-bucket
26+
UPLOAD_PATH_PREFIX: sandbox-xqueue
27+
USERS:
28+
lms: password
29+
XQUEUES:
30+
certificates: null
31+
edX-Open_DemoX: http://localhost:18050
32+
open-ended: null
33+
open-ended-message: null
34+
test-pull: null

docker-compose.yml

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -645,12 +645,16 @@ services:
645645

646646
xqueue:
647647
container_name: "edx.${COMPOSE_PROJECT_NAME:-devstack}.xqueue"
648-
image: edxops/xqueue:${OPENEDX_RELEASE:-latest}
648+
image: edxops/xqueue-dev:${OPENEDX_RELEASE:-latest}
649+
working_dir: /edx/app/xqueue/xqueue
649650
command: bash -c 'source /edx/app/xqueue/xqueue_env && while true; do python /edx/app/xqueue/xqueue/manage.py runserver 0.0.0.0:18040 ; sleep 2; done'
650651
volumes:
651652
- ${DEVSTACK_WORKSPACE}/xqueue:/edx/app/xqueue/xqueue
653+
- ${PWD}/configuration_files/xqueue.yml:/edx/etc/xqueue.yml
652654
depends_on:
653655
- mysql57
656+
environment:
657+
XQUEUE_CFG: "/edx/etc/xqueue.yml"
654658
networks:
655659
default:
656660
aliases:
@@ -660,10 +664,12 @@ services:
660664

661665
xqueue_consumer:
662666
container_name: "edx.${COMPOSE_PROJECT_NAME:-devstack}.xqueue_consumer"
663-
image: edxops/xqueue:${OPENEDX_RELEASE:-latest}
667+
image: edxops/xqueue-dev:${OPENEDX_RELEASE:-latest}
668+
working_dir: /edx/app/xqueue/xqueue
664669
command: bash -c 'source /edx/app/xqueue/xqueue_env && while true; do python /edx/app/xqueue/xqueue/manage.py run_consumer ; sleep 2; done'
665670
volumes:
666671
- ${DEVSTACK_WORKSPACE}/xqueue:/edx/app/xqueue/xqueue
672+
- ${PWD}/configuration_files/xqueue.yml:/edx/etc/xqueue.yml
667673
depends_on:
668674
- mysql57
669675
networks:

0 commit comments

Comments
 (0)