Opigno LMS User manual
Upgrade from Opigno LMS 2.x to Opigno LMS 3.x
Before any upgrade, a full backup of your Opigno instance (database and files) should be done, so that you can revert to the previous version in case the upgrade doesn't go well.
If you want to quickly check if your Opigno instance is up-to-date, you can simply click in the user menu on "About". You will see your version of Opigno as well as a green pictogram if it's up-to-date:
This assumes that you are already using Opigno 2.x (this does not cover upgrading from Opigno 1.x branch).
This also assumes that you initially installed Opigno using Composer. If you initially installed Opigno by downloading the tarball version, upgrade with Composer won't work.
As of Opigno 3.x, only Composer is advised for installation and upgrade.
Update to Opigno LMS latest version (at the time of writing this manual it is 8.x-2.29)
If there are updates for Opigno LMS you can easily install them with Composer.
All Composer commands must be executed in the folder of your project at the same level as the folders web, drush etc.
First, you need to check if updates are available:
composer outdated opigno/opigno_lms
If 'version' and 'latest' are different that means updates are available.
Install updates:
- UPDATING TO 8.x-2.29 version: get this composer.json file. Then replace your old composer.json with a new one and then run the commands below
NOTE: if you already installed some packages that are not part of Opigno LMS you should include them in a new composer.json file, otherwise Composer may remove them
// Clear composer cache
composer clearcache
// Check if updates will run without any issues
composer update --dry-run
// Run updates
composer update
During the update process, some warnings may appear in relation with some modules (drupal/calendar, drupal/views_role_based_global_text), mentioning that they were modified, and asking "Discard changes?". The answer should be "y".
These modules will be updated to new versions.
Then update database and clear cache in admin interface or by Drush:
drush updatedb
drush cr
Typical problems:
If updates are available but can't be installed you can run this command to check the reasons why it can't be done:
Upgrade from Opigno LMS 2.x to Opigno LMS 3.x
Updating is possible only from the latest version (at the time of writing this manual it is 8.x-2.29)
The first step is to check hosting environment matches the platform requirements of Drupal 9. The upgrade process is largely related to the transition to D9 and we will check using the Upgrade Status project to check contrib and custom modules compatibility.
While Drupal core does not require Drush, many people do use Drush. Drush will only provide Drupal 9 compatibility in Drush 10.
Make and save a complete dump of your site, files, database, and other important information in a safe place before updating. Also, check the structure changes before starting the update (Configuration and content structure changes.)
Note: Your composer may be different, but below are the common known upgrade paths from Opigno LMS 2.x to Opigno LMS 3.x.
Move the contents of the composer.json file to your directory then delete composer.lock file and run $ composer install
If your version contains many differences from the standard version, which is often the case on projects, use the instructions step by step, which may be preferable. There will also be a list of all changes to the composer file at the end.
1. Install Drush 10.
2. Update a project requirement.
The Opigno LMS 2.x dependency list has been updated to look like this:
if you do not install modules manually, then you can lead to the following form:
and Opigno LMS 3.x will install all the necessary packages for you
3. Repository list
Upgrade or roll back to the release version 3.0.2:
The latest composer.json with a repository list https://bitbucket.org/opigno/opigno-composer/src/3.0.2/composer.json .
Upgrade or roll back to the release version 3.0.1:
We are recommending upgrading to the latest version: Upgrade to the 3.0.2 release., but it is possible to follow this instruction for versions <= 3.0.1
We'll come back to the detailed review of the changes and the repository list, but now we will make a few important changes.
add exclude section and drupal/h5p module.
Then add the repository:
The minimum required is ready and now you can run $ composer update
. As mentioned earlier you can
Troubleshooting
If this fails with Your requirements could not be resolved…you may need to remove composer.lock and vendor folder. This trick will work if all your modules are installed via composer $ composer install
Configuration and content structure changes.
Duration field
The duration files type was changed to the entity reference type. This change allows improving filtering on the category page.
Color theme
The default color scheme was changed so you need to check the custom colors settings after update to the Aristotle theme (in case your site uses the custom theme setting instead of default):
Copyright 2008-2024 Connect-i. All Rights Reserved - https://www.opigno.org