@@ -10,28 +10,23 @@ WordPress Plugin for `Tutor`_
1010 :target: https://www.gnu.org/licenses/agpl-3.0.en.html
1111
1212Overview
13- --------
13+ ********
1414
15- This is a `Tutor `_ plugin for integrating the `Open edX Commerce WordPress Plugin `_ with your Open edX instance.
16- The plugin allows seamless synchronization and interaction between your WordPress site and Open edX platform,
17- providing a cohesive e-commerce experience. If you don't know how to install the WordPress plugin, check out
18- this `installation guide `_.
15+ This is a `Tutor `_ plugin that provides complete WordPress integration with your Open edX instance. It includes:
1916
20- Before you start
21- ----------------
17+ - Full WordPress installation and management
18+ - Integration with the ` Open edX Commerce WordPress Plugin `_
2219
23- This plugin does **not ** create or manage a WordPress instance at the moment. It is designed to assist with the
24- configuration and integration of the Open edX platform with an existing WordPress site. If you need this feature,
25- feel free to open an issue or better yet, a PR.
20+ If you need help installing the WordPress plugin, check out this `installation guide `_.
2621
2722Prerequisites
28- -------------
23+ *************
2924
30- - A running WordPress site with the ` Open edX Commerce WordPress Plugin `_ installed.
31- - Installation of Tutor version >= 15.0.0.
25+ - Installation of Tutor version >= 15.0.0
26+ - MySQL database (can use the same one as Open edX)
3227
3328Installation
34- ------------
29+ ************
3530
3631Ensure you are using Tutor v15+ (Olive onwards). First, install the plugin by running:
3732
@@ -51,59 +46,95 @@ Alternatively, if you already have a running Open edX instance, just run the nec
5146.. code-block :: bash
5247
5348 tutor dev| local| k8s do init --limit=wordpress
49+ tutor dev| local| k8s start wordpress
5450
5551 Configuration
56- -------------
52+ *************
5753
58- Inside your WordPress admin panel, you will need to configure the following values:
54+ The plugin automatically installs WordPress with the Open edX Commerce and Woocommerce plugins. Inside your WordPress
55+ admin panel, go to Settings -> Open edX Sync plugin, and configure:
5956
6057- **Open edX Domain **
6158- **Client ID **
6259- **Client Secret **
6360
61+ To verify the connection, click on "Generate JWT Token". If the process is successful, a new token will be generated.
62+
6463.. image :: https://raw.githubusercontent.com/codewithemad/tutor-contrib-wordpress/master/images/openedx-sync-plugin-settings.png
6564 :alt: Open edX Sync Plugin Settings in your WordPress Settings
6665
67-
6866You can retrieve these configuration values by running:
6967
7068.. code-block :: bash
7169
72- tutor wordpress config
70+ tutor dev | local | k8s do wordpress config
7371
72+ This command will output the current configurations, including the Client ID, Client Secret, Open edX Domain,
73+ and WordPress Domain. Here is an example of the output:
7474
7575.. code-block :: text
7676
7777 ===============================================
78- WordPress Plugin Configurations
78+ WordPress Plugin Configurations
7979 ===============================================
8080
81- Open edX Domain: http://local.edly.io
82- Client ID: qjCayDktffXrU09N17NrslKyWQ2EwzWn
83- Client ID (dev): JDx6Uy0hN67VUfacxKcLyYQz7HK9liVx
84- Client Secret: P4w82huaZQdyz4qolknsIHYneGEoIggc
81+ Client ID: vvpTamiepPwjZhr0uOQGr5PhYBzp2hQw
82+ Client ID (dev): MlbXk1V3wB7nWPAAyLF3McyfBBMqExa4
83+ Client Secret: MdrgbtU8Q94He3gejF6Zf5MDookoeozO
8584
85+ Open edX Domain: http://local.edly.io:8000
86+ Wordpress Domain: http://site.local.edly.io:8080
8687
87- Or by using Tutor to print them individually:
88+ Variables
89+ *********
8890
89- .. code-block :: bash
91+ The plugin supports the following configuration variables:
92+
93+ - ``WORDPRESS_VERSION ``: Plugin version
94+ - ``WORDPRESS_HOST ``: WordPress site hostname
95+ - ``WORDPRESS_PORT ``: WordPress port (default: 8080)
96+ - ``WORDPRESS_DOCKER_IMAGE ``: Docker image for WordPress
97+ - ``WORDPRESS_OPENEDX_PLUGIN ``: URL to the Open edX Commerce plugin
98+ - ``WORDPRESS_WOOCOMMERCE_PLUGIN ``: (default: "https://downloads.wordpress.org/plugin/woocommerce.9.4.2.zip")
99+ The WooCommerce plugin zip file URL. You can specify a different version if needed.
100+ - ``WORDPRESS_OFFICIAL_IMAGE ``: (default: "wordpress:6.7.1-php8.1")
101+ The official WordPress Docker image used as the base for building the plugin's custom image.
102+ This image includes PHP and Apache server. You can specify a different version or PHP variant
103+ if needed.
104+
105+ Database Settings
106+ =================
107+
108+ - ``WORDPRESS_MYSQL_HOST ``: MySQL host
109+ - ``WORDPRESS_MYSQL_PORT ``: MySQL port
110+ - ``WORDPRESS_MYSQL_DATABASE ``: Database name (default: wordpress)
111+ - ``WORDPRESS_MYSQL_USERNAME ``: Database username
112+ - ``WORDPRESS_MYSQL_PASSWORD ``: Database password (auto-generated)
113+ - ``WORDPRESS_TABLE_PREFIX ``: Table prefix (default: wp _)
90114
91- tutor config printvalue LMS_HOST
92- tutor config printvalue WORDPRESS_OAUTH2_SECRET
93- tutor config printvalue WORDPRESS_OAUTH2_KEY_SSO
94- tutor config printvalue WORDPRESS_OAUTH2_KEY_SSO_DEV
115+ Storage Settings
116+ ================
117+
118+ - ``WORDPRESS_DATA_VOLUME_SIZE ``: Size of WordPress persistent volume (default: 5Gi)
119+
120+ OAuth2 Settings
121+ ===============
122+
123+ - ``WORDPRESS_OAUTH2_SECRET ``: OAuth2 secret key (auto-generated)
124+ - ``WORDPRESS_OAUTH2_KEY_SSO ``: OAuth2 client ID (auto-generated)
125+ - ``WORDPRESS_OAUTH2_KEY_SSO_DEV ``: OAuth2 development client ID (auto-generated)
95126
96127Contributing
97- ------------
128+ ************
98129
99- We welcome all contributions! Feel free to open a Pull Request.
130+ We welcome all contributions! Feel free to open a Pull Request or an Issue .
100131
101132License
102- -------
133+ *******
103134
104135This software is licensed under the terms of the `AGPLv3 `_.
105136
106137.. _Tutor : https://docs.tutor.edly.io
107- .. _installation guide : https://docs.openedx.org/projects/wordpress-ecommerce-plugin/en/latest/plugin_quickstart.html
108138.. _Open edX Commerce WordPress Plugin : https://github.com/openedx/openedx-wordpress-ecommerce
109139.. _AGPLv3 : https://github.com/codewithemad/tutor-contrib-wordpress/blob/master/LICENSE.txt
140+ .. _installation guide : https://docs.openedx.org/projects/wordpress-ecommerce-plugin/en/latest/plugin_quickstart.html
0 commit comments