From 9c48597734c3265bbee5cc38b358e86a2123bd06 Mon Sep 17 00:00:00 2001 From: Maxence Lange Date: Fri, 28 Jul 2017 17:32:11 +0200 Subject: [PATCH] 1.0.0 --- README.md | 59 ++++++++++++++++++++++++++++++++++++++++++++++++++++--- 1 file changed, 56 insertions(+), 3 deletions(-) diff --git a/README.md b/README.md index 8123d22..a19da5d 100755 --- a/README.md +++ b/README.md @@ -1,5 +1,58 @@ -# README -Based on [https://github.com/pssl16/moodle-repository_owncloud](https://github.com/pssl16/moodle-repository_owncloud) -Documentation is WIP \ No newline at end of file +# Installation + +- Download the [Moodle Nextcloud Repository plugin from the release page](https://github.com/daita/moodle-repository_nextcloud/releases) +- Download the [Moodle Tool OAuth2 from pssl16](https://github.com/pssl16/moodle-tool_oauth2owncloud/releases) + + + +# Configuration + +- 1 - Setup the Oauth2 information in Nextcloud. + +From your admin account, navigate to the _Security_ settings page to add a new entry for your moodle in the _OAuth 2.0 clients_ list. + +![](https://raw.githubusercontent.com/daita/moodle-repository_nextcloud/master/pix/admin_oauth2.png) + +In the **Add client** form, choose a name and set up the redirection URI to your moodle that will redirect your user after authentication. +> Note: The **Redirection URI** have to be https://yourmoodle.example.com/admin/oauth2callback.php + +After clicking the **Add** button, you should see the Client Identifier and a Secret key in front of your freshly created entry. Those 2 strings will be used in _moodle_ during the setup of this plugin. + + + + +*** +- 2 - Setup the moodle-tool_oauth2owncloud + +From the moodle site administration, in the plugins tab, select Admin tools/ownCloud OAuth 2.0 Configuration. + +![](https://raw.githubusercontent.com/daita/moodle-repository_nextcloud/master/pix/setup_oauth2.png) +Fill the correct information using the **Client ID** and the **Secret** you get from Nextcloud (see the first step of this guide). +Enter the Nextcloud server address and the webdav path: `remote.php/webdav/`. Select the right Protocol and change the port if needed. + +Save changes. + + + + +*** +- 3 - From the moodle site administration, in the plugins tab, select **Repositories/Nextcloud**. + +You will be prompted to define a name to the plugin (default is Nextcloud). +After that, you will see the list of all available repositories on your Moodle. Search for **Nextcloud** and set its Active status to '_Enabled and Visible_' + +![](https://raw.githubusercontent.com/daita/moodle-repository_nextcloud/master/pix/setup_enable.png) + + +*** + +Your plugin is now configured, If you navigate to your **Private files** you should see the Nextcloud repository and log into your account. + +![](https://raw.githubusercontent.com/daita/moodle-repository_nextcloud/master/pix/file_picker_login.png) +![](https://raw.githubusercontent.com/daita/moodle-repository_nextcloud/master/pix/file_picker_listing.png) + +# More information + +Plugin is based on [https://github.com/pssl16/moodle-repository_owncloud](https://github.com/pssl16/moodle-repository_owncloud)