XWiki is a wiki program that allows anyone to create, organize and share information from any device with internet access, using a web browser, desktop computer or mobile phone.
It is a complete community wiki hosting service with user rights, roles and groups. It has both public and private wikis. A database, such as MySQL, is used to store information. Servlet containers are used for work (for example, Tomcat, Jetty); XHTML, WYSIWYM, XSL-FO, MathML, SVG and RSS are supported.
XWiki is the next generation of Wiki, the only wiki on the market to offer so many features in one package.
XWiki offers an advanced mode that can be enabled on any wiki, allowing more fine-grained control over how content is rendered using XSLT-based transformation rules. It comes with a set of default style sheets pre-configured to work out of the box. However, this behavior can be easily customized using custom XSLT files, giving you complete freedom to create the look and feel of the wiki without having to write any code.
In this guide, you will learn how to install XWiki on Ubuntu 20.04 and get users, permissions, and basic features. While this guide is based on Ubuntu 20.04, the instructions can be applied to any Debian-based distribution.
The necessary conditions
- Server running Ubuntu 20.04 with at least 1024 MB RAM and at least 20 GB hard drive.
- Domain name for accessing the wiki from the Internet (optional).
- Basic knowledge of Linux and web servers in general.
- Root server access or sudo user privileges to install applications and manage files and directories on your server.
System update
To make sure that the system requirements are met, you must first update it. Update your distribution's package list by running the command:
sudo apt-get update
You should get the following result:
After updating the lists of available packages, run the command below to install all updates on Ubuntu 20.04:
sudo apt-get upgrade -y
or
sudo apt-get dist-upgrade -y
You should get the following result:
It is recommended that you restart your server before applying any kernel updates so that they take effect properly and avoid problems later when using some XWiki modules, such as document conversion services, which are highly dependent on a working version of the Linux kernel.
sudo reboot now
After that, log in again with the same sudo user and proceed to the next step.
Install Java
XWiki is written in Java, so you'll need to install Java on Ubuntu 20.04 before continuing.
To install Java on Ubuntu 20.04, run the following command:
sudo apt install default-jdk -y
You should get the following result:
You can check the Java version with the following command after installing it:
java --version
You should get the following result:
Now that Java is properly installed, you can proceed to the next step.
Installing XWiki on Ubuntu 20.04
By default, XWiki is not available in the Ubuntu 20.04 repositories, so you will have to download the package from the XWiki website and manually install it on your server.
First of all, make sure wget and curl are installed:
sudo apt-get -y install wget curl
Add the GPG key to apt with the following command:
wget -q " -O- | apt-key add -
You should see an OK message confirming that the key was added correctly.
Add the XWiki repository to your system with the following command:
sudo wget " -P /etc/apt/sources.list.d/
The above command will add the stable XWiki repository to your server.
You should get the following result:
In order for apt to use the newly added repositories, you need to update its cache:
sudo apt-get update -y
At this stage Xwiki is available in your Ubuntu 20.04 repositories, you can find available packages with the following command:
sudo apt-cache search xwiki
A list of packages will appear from which you can select the package you want to install.
XWiki on Ubuntu 20.04 requires an external servlet container such as Apache Tomcat. In this tutorial, we will install the xwiki-platform package with tomcat 9 and MariaDB as the database server:
sudo apt install xwiki-tomcat9-common xwiki-tomcat9-mariadb -y
During the installation process, you will need to create the XWiki database as shown below. Select "Yes" and press Enter to start the database creation process.
Set the password you want, select Ok and press Enter when prompted to complete setting the password for the XWiki database as shown below. Be sure to confirm it after that.
When the installation is complete, you can check the Tomcat service with the following command:
sudo systemctl status tomcat9.service
You should see the following output:
As you can see, the tomcat service is active and running.
Normally Tomcat is listening on port 8080. You can check if it is listening on port 8080 using the following command:
ss -antpl | grep 8080
You should see the following output:
Configuring Nginx for XWiki
In this part, we will tell you how to set up Nginx for XWiki. Nginx is a very popular and powerful web server. It can be used to serve static content, proxy requests, and handle authentication lightly, among other things.
In order for Nginx to communicate with the XWiki tomcat application, it must be configured accordingly.
To install the Nginx web server, enter the following command in a terminal:
sudo apt-get install nginx -y
After installing the web server, create a new Nginx configuration file with the following command called xwiki.conf. xwiki.conf is a config file that needs to be updated with your own settings and will be stored in the etc folder.
sudo nano /etc/nginx/sites-available/xwiki.conf
An empty file should open in front of you, ready for editing.
Fill the file with the following content:
server { listen 80; server_name xwiki.example.com; access_log /var/log/nginx/xwiki-access.log; error_log /var/log/nginx/xwiki-error.log; location / { proxy_set_header X-Real-IP $remote_addr; proxy_set_header Host $host; proxy_http_version 1.1; proxy_set_header Upgrade $http_upgrade; proxy_set_header Connection 'upgrade'; proxy_cache_bypass $http_upgrade; proxy_pass } }
Save the file when finished, then activate the new Nginx configuration with the following command:
sudo ln -s /etc/nginx/sites-available/xwiki.conf /etc/nginx/sites-enabled/
Restart Nginx for the changes to take effect with the following command:
sudo systemctl restart nginx
Accessing the XWiki web interface
Now that you've installed and configured XWiki, it's time to access the web interface. To do this, enter your server's IP address or domain name followed by /xwiki. For example:
You will see a welcome window as shown in the picture.
Click the Continue button. You should see the admin user creation page.
Now you need to create your first XWiki user account by filling in all the required information as shown below:
Enter your username, password, and email, then click the Register and Login button. You will be taken to the page below:
Click on the Continue button. You will see the following page. Select the flavor you want to use and click the Install this flavor button as shown in the picture.
Once the installation is complete, you should see the following page:
To apply the settings, click the Continue button. Once the installation is complete, you will see the following page showing the default XWiki folders. Click Continue to complete the installation.
Finally, you should see the default XWiki dashboard, as shown below:
Conclusion
In this tutorial, you learned how to install Xwiki on Ubuntu 20.04 and set up Nginx for it. We hope this guide has been helpful to you.
For more information about XWiki, please visit official site
2734500cookie-checkHow to install XWiki on Ubuntuno
similar
Инструкции,Обзоры,Программы,ubuntu,Wiki,XWiki
#Install #XWiki #Ubuntu