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

Discovery ansible free config #994

Merged
merged 1 commit into from
Jan 24, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -421,7 +421,7 @@ dev.shell.credentials:
docker-compose exec credentials env TERM=$(TERM) bash -c 'source /edx/app/credentials/credentials_env && cd /edx/app/credentials/credentials && /bin/bash'

dev.shell.discovery:
docker-compose exec discovery env TERM=$(TERM) /edx/app/discovery/devstack.sh open
docker-compose exec discovery env TERM=$(TERM) bash -c '/bin/bash'

dev.shell.ecommerce:
docker-compose exec ecommerce env TERM=$(TERM) /edx/app/ecommerce/devstack.sh open
Expand Down
94 changes: 94 additions & 0 deletions configuration_files/discovery.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,94 @@
---


API_ROOT: null
AWS_SES_REGION_ENDPOINT: email.us-east-1.amazonaws.com
AWS_SES_REGION_NAME: us-east-1
BACKEND_SERVICE_EDX_OAUTH2_KEY: discovery-backend-service-key
BACKEND_SERVICE_EDX_OAUTH2_PROVIDER_URL: http://localhost:18000/oauth2
BACKEND_SERVICE_EDX_OAUTH2_SECRET: discovery-backend-service-secret
CACHES:
default:
BACKEND: django.core.cache.backends.memcached.MemcachedCache
KEY_PREFIX: discovery
LOCATION:
- edx.devstack.memcached:11211
CELERY_BROKER_URL: redis://:@127.0.0.1:6379/
CORS_ORIGIN_WHITELIST: []
CSRF_COOKIE_SECURE: false
DATABASES:
default:
ATOMIC_REQUESTS: 'false'
CONN_MAX_AGE: 60
ENGINE: django.db.backends.mysql
HOST: edx.devstack.mysql
NAME: discovery
OPTIONS:
connect_timeout: 10
init_command: SET sql_mode='STRICT_TRANS_TABLES'
PASSWORD: password
PORT: 3306
USER: discov001
read_replica:
ATOMIC_REQUESTS: 'false'
CONN_MAX_AGE: 60
ENGINE: django.db.backends.mysql
HOST: edx.devstack.mysql
NAME: discovery
OPTIONS:
connect_timeout: 10
init_command: SET sql_mode='STRICT_TRANS_TABLES'
PASSWORD: password
PORT: 3306
USER: discov001
DEFAULT_PARTNER_ID: 1
EDX_DRF_EXTENSIONS:
OAUTH2_USER_INFO_URL: http://127.0.0.1:8000/user_info
ELASTICSEARCH_CLUSTER_URL: http://127.0.0.1:9200/
ELASTICSEARCH_INDEX_NAME: catalog
EMAIL_BACKEND: django_ses.SESBackend
EMAIL_HOST: localhost
EMAIL_HOST_PASSWORD: ''
EMAIL_HOST_USER: ''
EMAIL_PORT: 25
EMAIL_USE_TLS: false
ENABLE_PUBLISHER: false
EXTRA_APPS:
- course_discovery.apps.edx_catalog_extensions
JWT_AUTH:
JWT_AUTH_COOKIE_HEADER_PAYLOAD: edx-jwt-cookie-header-payload
JWT_AUTH_COOKIE_SIGNATURE: edx-jwt-cookie-signature
JWT_AUTH_REFRESH_COOKIE: edx-jwt-refresh-cookie
JWT_ISSUERS:
- AUDIENCE: lms-key
ISSUER: http://edx.devstack.lms:18000/oauth2
SECRET_KEY: lms-secret
JWT_PUBLIC_SIGNING_JWK_SET: ''
LANGUAGE_CODE: en
MEDIA_STORAGE_BACKEND:
DEFAULT_FILE_STORAGE: django.core.files.storage.FileSystemStorage
MEDIA_ROOT: /edx/var/discovery/media
MEDIA_URL: /media/
OPENEXCHANGERATES_API_KEY: ''
PARLER_DEFAULT_LANGUAGE_CODE: en
PARLER_LANGUAGES:
1:
- code: en
default:
fallbacks:
- en
hide_untranslated: 'False'
PLATFORM_NAME: Your Platform Name Here
PUBLISHER_FROM_EMAIL: null
SECRET_KEY: Your secret key here
SESSION_EXPIRE_AT_BROWSER_CLOSE: false
SOCIAL_AUTH_EDX_OAUTH2_ISSUER: http://127.0.0.1:8000
SOCIAL_AUTH_EDX_OAUTH2_KEY: discovery-sso-key
SOCIAL_AUTH_EDX_OAUTH2_LOGOUT_URL: http://localhost:18000/logout
SOCIAL_AUTH_EDX_OAUTH2_SECRET: discovery-sso-secret
SOCIAL_AUTH_EDX_OAUTH2_URL_ROOT: http://127.0.0.1:8000
SOCIAL_AUTH_REDIRECT_IS_HTTPS: false
STATICFILES_STORAGE: django.contrib.staticfiles.storage.StaticFilesStorage
STATIC_ROOT: /edx/var/discovery/staticfiles
TIME_ZONE: UTC
USERNAME_REPLACEMENT_WORKER: OVERRIDE THIS WITH A VALID USERNAME
3 changes: 2 additions & 1 deletion docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -346,7 +346,7 @@ services:
TEST_ELASTICSEARCH_URL: "edx.devstack.elasticsearch710"
ENABLE_DJANGO_TOOLBAR: 1
DJANGO_WATCHMAN_TIMEOUT: 30
image: edxops/discovery:${OPENEDX_RELEASE:-latest}
image: edxops/discovery-dev:${OPENEDX_RELEASE:-latest}
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The tests will fail for now since I haven't pushed the image until now. I will re run the CI tests once openedx/course-discovery#3575 has been merged and the Ansible free image is available on edxops

networks:
default:
aliases:
Expand All @@ -355,6 +355,7 @@ services:
- "18381:18381"
volumes:
- discovery_assets:/edx/var/discovery/
- ${PWD}/configuration_files/discovery.yml:/edx/etc/discovery.yml

ecommerce:
command: bash -c 'source /edx/app/ecommerce/ecommerce_env && while true; do python /edx/app/ecommerce/ecommerce/manage.py runserver 0.0.0.0:18130; sleep 2; done'
Expand Down