What is SubjectsPlus?
It is the information, content creation, management and pathfinder Software that is free and Open Source created by Ithaca College Library, and presently, it is maintained by the University of Miami Libraries, this (SubjectsPlus) is based on web 2.0 library information sharing system tools to manage and organize resources effectively.
This software is mostly used by Librarians and subject experts in many ways such as
- To create different guides
- Subject Guide
- Research Guide
- Course Guide
- Audio-Visual Guide
- Subject-Expert Guide
- To create directories/bibliographies
- Staff Directory
- Customize bibliographies for the user
- To create the list of Subscribed and open-source resources/databases
- A to Z list of library resources.
- A to Z list of database.
- To create a content management system (CMS)
Due to its nature, we can customise this according to the needs of our users
and staff by providing an excellent graphical user interface (GUI).
How to install it?
LAMP
- L - Linux (Operating System)
- A - Apache (Web Server)
- M - MySQL/ MariaDB (Relational Database Management System)
- P - PHP (Hypertext Preprocessor)
WAMP
- W - Windows (Operating System)
- A - Apache (Web Server)
- M - MySQL/ MariaDB (Relational Database Management System)
- P- PHP (Hypertext Preprocessor)
MAMP
- M - macOS (Operating System)
- A - Apache (Web Server)
- M - MySQL/ MariaDB (Relational Database Management System)
- P - PHP (Hypertext Preprocessor)
Prerequisites (for version 4.6)
- LAMP
- L - Linux (Operating System)
- Ubuntu 22.04
- A - Apache (Web Server)
- Apache2
- M - MySQL/ MariaDB (Relational Database Management System)
- MySQL 5.6/5.7 or
- MariaDB 10.x
- P - PHP (Hypertext Preprocessor)
- PHP 7.4
Step 1: Update and upgrade the Ubuntu OS
sudo apt update && sudo apt upgrade -y
sudo apt update && sudo apt upgrade -y
Step 2: Installation of apache2 web server
sudo apt install apache2
Step 3: Install PHP and Required Extensions
- Dependencies Installation
sudo apt install software-properties-common ca-certificates lsb-release apt-transport-https
- Add Ondrej PPA to the sytem
LC_ALL=C.UTF-8 sudo add-apt-repository ppa:ondrej/php
- Update Package Manager Cache
sudo apt update
- Install PHP 7.4
sudo apt install php7.4 php7.4-cli php7.4-fpm php7.4-mysql php7.4-json php7.4-curl php7.4-mbstring php7.4-xml php7.4-zip php7.4-gd php7.4-intl php7.4-gettext
Step 4: Install and Configure MariaDB
sudo apt install mariadb-server
This script will prompt you to perform actions such as setting the
root password, removing anonymous users,
disallowing remote root login, and
removing test databases.sudo mysql_secure_installation
This command opens MariaDB server console using the root user and prompts you for the root password.
sudo mysql -u root -p
CREATE DATABASE subjectsplus;
This command creates a new user named spuser who can connect from the
localhost (the same machine) and specifies the user's password.
CREATE USER 'spuser'@'localhost' IDENTIFIED BY 'your_password';
This command grants all privileges on the subjectsplus database to the spuser user, allowing them to perform various operations on the database.
GRANT ALL PRIVILEGES ON subjectsplus.* TO 'spuser'@'localhost';
This command reloads the privileges to apply the changes you've made.
FLUSH PRIVILEGES;
EXIT;
Step 4: Download the required files from the GitHub page and Install SubjectsPlus
cd /var/www/html
sudo wget https://github.com/subjectsplus/SubjectsPlus/archive/refs/tags/v4.6.tar.gz
sudo tar -xvf v4.6.tar.gz
sudo mv SubjectsPlus-4.6 guide
cd guide
Step 5: Change Folder Ownership
sudo chown -R www-data:www-data /var/www/html/guide
Step 6: Folder permission
- For /guide/control/includes/config-default.php:
chmod 644 /var/www/html/guide/control/includes/config-default.php
- For /guide/control/includes/ (and files within it):
chmod 755 /var/www/html/guide/control/includes/
- For /guide/subjects/.htaccess:
chmod 664 /var/www/html/guide/subjects/.htaccess
- For /guide/api/.htaccess:
chmod 664 /var/www/html/guide/api/.htaccess
- For /guide/assests/users/ (and files within it):
chmod 755 /var/www/html/guide/assests/users/
- For /guide/assests/cache/
chmod 755 /var/www/html/guide/assests/cache/
- For /guide/assets/images/video_thumbs
chmod 755 /var/www/html/guide/assests/images/video_thumbs
7 is equivalent to rwx (read, write, and execute)
6 is equivalent to rw- (read and write)
5 is equivalent to r-x (read and execute)
4 is equivalent to r-- (read only)
So, chmod 755 grants read, write, and execute permissions to the owner, and read and execute permissions to the group and others.
Step 7: Configure Apache
Create a virtual host configuration for SubjectsPlus:
sudo nano /etc/apache2/sites-available/guide.conf
Add the following configuration:
<VirtualHost *:80> ServerName localhost DocumentRoot /var/www/html/guide <Directory /var/www/html/guide> AllowOverride All Require all granted </Directory> ErrorLog ${APACHE_LOG_DIR}/error.log CustomLog ${APACHE_LOG_DIR}/access.log combined </VirtualHost>
sudo a2dissite 000-default.conf
sudo a2ensite guide.conf
sudo systemctl restart apache2
Step 8: change the require setting in the files for password display
cd /var/www/html/guide/lib/SubjectsPlus/Control/
sudo nano Installer.php
After making change then save the file and the block of code look like this:
/**
* Rename subjects/.htaccess-default to .htaccess and api/.htaccess-default to .htaccess
* .htaccess files were added to .gitignore on 5-10-19
* @return array
*/
private function rewriteHtaccessFilenames() {
//get root to subjectsplus path
$lstrRootPath = dirname( dirname( dirname( dirname( __FILE__ ) ) ) ) . DIRECTORY_SEPARATOR;
if( (file_exists($lstrRootPath . 'subjects' . DIRECTORY_SEPARATOR . '.htaccess-default')) && (!file_exists($lstrRootPath . 'subjects' . DIRECTORY_SEPARATOR . '.htaccess')) ) {
$subjectsHtaccess = rename($lstrRootPath . 'subjects' . DIRECTORY_SEPARATOR . '.htaccess-default', $lstrRootPath . 'subjects' . DIRECTORY_SEPARATOR . '.htaccess');
$subjectsHtaccess = $lstrRootPath . 'subjects' . DIRECTORY_SEPARATOR . '.htaccess';
}
if( (file_exists($lstrRootPath . 'api' . DIRECTORY_SEPARATOR . '.htaccess-default')) && (!file_exists($lstrRootPath . 'api' . DIRECTORY_SEPARATOR . '.htaccess')) ) {
$apiHtaccess = rename($lstrRootPath . 'api' . DIRECTORY_SEPARATOR . '.htaccess-default', $lstrRootPath . 'api' . DIRECTORY_SEPARATOR . '.htaccess');
$apiHtaccess = $lstrRootPath . 'api' . DIRECTORY_SEPARATOR . '.htaccess';
}
return array( $subjectsHtaccess, $apiHtaccess);
}
}
No comments:
Post a Comment