Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

You can define all required and optional Swift settings at one time, or you can update settings as needed over time. Each time you update the server-vars.yml file, you must run the update command playbook roles and restart the LMS server.

...

  1. Stop the LMS server.
  2. Create or edit the /edx/app/edx_ansible/server-vars.yml file.
    Be sure to replace any example values for the settings that follow with values that apply to your instance.
  3. Define or verify the following settings.

     EDXAPP_SETTINGS: "openstack"    

VHOST_NAME: "openstack"

...

  1. To configure Swift, define values for each of the following settings. The

...

  1. EDXAPP_SWIFT_AUTH_

...

  1. VERSION can be set to either

...

  1. 1 or

...

  1. 2, and

...

  1. defaults to

...

  1. 1 if not specified.

   .. code-block:: yaml

...

EDXAPP_SWIFT_USERNAME: ""

...

EDXAPP_SWIFT_KEY: ""

...

EDXAPP_SWIFT_TENANT_ID: ""

...

EDXAPP_SWIFT_TENANT_NAME: ""

...

EDXAPP_SWIFT_AUTH_URL: ""

...

EDXAPP_SWIFT_AUTH_VERSION:

...

EDXAPP_SWIFT_REGION_NAME: ""

...

  1. Customize the name of the Swift container that your system's files will be

...

  1. uploaded to by defining the following setting.

   .. code-block:: yaml

...

EDXAPP_FILE_UPLOAD_STORAGE_BUCKET_NAME: "container_name"

...

  1. To configure storage for grade reports, define the following settings. The

...

  1. name_

...

  1. prefix that you define specifies a common prefix for the files

...

  1. generated by the system.

   .. code-block:: yaml

...

EDXAPP_GRADE_STORAGE_CLASS: 'swift.storage.SwiftStorage'

...

EDXAPP_GRADE_STORAGE_KWARGS:

...

name_prefix: "grades/"

...

.

...

.

...

.

...

ENABLE_GRADE_DOWNLOADS: true

   You can continue on to define Swift settings for other features, or complete    the following steps to update your instance.#.

  1. Run the following roles.

   ::

...

cd /edx/app/edx_ansible/edx_ansible/playbooks

...

sudo /edx/app/edx_ansible/venvs/edx_ansible/bin/ansible-playbook -i localhost, -c local -e@/edx/app/edx_ansible/server-vars.yml run-role.yml -e 'role=edxapp' -e 'edx_platform_version=<your branch name>'

...

sudo /edx/app/edx_ansible/venvs/edx_ansible/bin/ansible-playbook -i localhost, -c local -e@/edx/app/edx_ansible/server-vars.yml run-role.yml -e 'celery_worker=True' -e 'role=edxapp' -e 'edx_platform_version=<your branch name>'

...

sudo /edx/app/edx_ansible/venvs/edx_ansible/bin/ansible-playbook -i localhost, -c local -e@/edx/app/edx_ansible/server-vars.yml run-role.yml -e 'role=edxapp' -e 'edxapp_code_dir=<path to edx-platform directory>'

...

...

  1. Restart the LMS server.

...

  1. Repeat this procedure for each instance that has data that you want to store

...

  1. on Swift.

============================================================


Define Swift Settings for Identity Verification (Proctoring)

============================================================

To define data storage for files that verify learner identity, follow these steps.#.

  1. Stop the LMS server.

...

  1. Edit the

...

  1. /edx/app/edx_ansible/server-vars.

...

  1. yml file.

...

  1. Verify that you have defined all of the

...

  1. required Swift settings.

...

  1. Define the following settings.

...

  1. Be sure to replace any example values for the settings that follow with

...

  1. values that apply to your instance.

   .. code-block:: yaml

...

EDXAPP_VERIFY_STUDENT:

...

DAYS_GOOD_FOR: 365

...

SOFTWARE_SECURE:

...

STORAGE_CLASS: "swift.storage.SwiftStorage"

...

STORAGE_KWARGS:

...

name_prefix: "photos/"

...

  1. Continue on to define Swift settings for other features, or complete steps

...

  1. 7-9 for

...

  1. defining required Swift

...

  1. settings to update your instance.

...

  1. Note that you only need to run the

...

  1. openstack role one time. If you are

...

  1. completing these identity verification configuration steps as a separate

...

  1. procedure, you need only run the

...

  1. edxapp role in step 7.

...

.. this note assumes that an openstack role actually got run somehow

...

Define Swift Settings for Temporary URLs

==========================================

To use temporary URLs for Swift, follow these steps.#.

  1. Stop the LMS server.

...

  1. Edit the

...

  1. /edx/app/edx_ansible/server-vars.

...

  1. yml file.

...

  1. Verify that you have defined all of the

...

  1. required Swift settings.

...

  1. Define the following settings.

...

  1. The duration setting is the value, in seconds, for how long a temporary URL

...

  1. remains valid.

...

...

SWIFT_USE_TEMP_URLS: true

...

SWIFT_TEMP_URL_KEY: ""

...

SWIFT_TEMP_URL_DURATION:

...

  1. Continue on to define Swift settings for other features, or complete steps

...

  1. 7-9 for

...

  1. defining required Swift

...

  1. settings to update your instance.

...

  1. Note that you only need to run the

...

  1. openstack role one time. If you are

...

  1. completing these temporary URL configuration steps as a separate

...

  1. procedure, you need only run the

...

  1. edxapp role in step 7.

.. this note assumes that an openstack role actually got run somehow

==========================================

Define Swift Settings for XQueue

==========================================

To define data storage for files for external graders, follow these steps.#.

  1. Stop the LMS server.

...

  1. Edit the

...

  1. /edx/app/edx_ansible/server-vars.

...

  1. yml file.

...

  1. Verify that you have defined all of the

...

  1. required Swift settings.

...

  1. Define the following settings.

...

  1. In a basic setup, the values for these variables are the same as for the

...

  1. EDXAPP_SWIFT_*

...

  1. settings.


   .. code-block:: yaml


     XQUEUE_SETTINGS: "openstack_settings"

...