Last update at :2024-05-03,Edit by888u
For a tutorial on building aria2, please see: http://www.138vps.com/vpsjc/945.html
This tutorial is mainly about building h5ai. h5ai is a very powerful directory listing program that can realize online playback of audio and video. With Aria2's offline download, it allows us to play online directly without moving back to the local computer after downloading the video.
The method of building h5ai is quite simple
1. According to the previous tutorial, we have already installed the http environment. Now we only need to install php. The method is as follows
centos 7:
rpm -Uvh https://mirror.webtatic.com/yum/el7/webtatic-release.rpm --force --nodeps
yum install php70w
service httpd restart
ubuntu:
apt-get install php
apt-get install libapache2-mod-php
/etc/init.d/apache2 restart
2. Download h5ai
Go to: https://larsjung.de/h5ai/ to download h5ai. The latest version is 0.29.0. We can download it directly. Or, the following two addresses: http://dl.138vps.com/Web%20app/h5ai.tar.gz and https://pan.lanzou.com/1133032
3. Upload the entire decompressed folder to [/var/www/html], the same directory as [webui], as shown below
centos
Modify the file [/etc/httpd/conf/httpd.conf] and add the following content at the end, paying attention to replacing relevant information.
ServerName your vpsIP:80NameVirtualHost your vpsIP
ServerAdmin admin@138vps.com
DocumentRoot /var/www/html/
ServerName your vpsIP
DirectoryIndex index index.html index.php /_h5ai/public/index.php
ubuntu:
Modify the file [/etc/apache2/mods-available/dir.conf], find something like [DirectoryIndex index.html index.cgi index.pl index.php index.xhtml index.htm], and change it to: [DirectoryIndex index index.html index.php /_h5ai/public/index.php].
Then refer to the method in the first step, restart your apache server, which is the last line of code in the first step, and just run it.
Access your IP and the following picture appears, indicating success. When using aria2 to download files, just download to the [/var/www/html] directory or subdirectory.
5. Other matters needing attention
If you need a better experience, you also need to remove the disabling of the following functions: scandir, exec, passthru
If you are using the one-click package or have already installed a website, please refer to the above tutorial and make changes according to the actual situation.
Regarding security issues, because it is direct IP access, everyone can use the offline download you set up, which will definitely consume a lot of traffic and is not safe, so it is recommended not to use IP access. The recommended approach is to prohibit IP access, then bind a non-existent domain name and access it by modifying the local host file. We have shared the specific method before, please look for it under the [Tutorial] or [Website Building Tutorial] column. certainly. For convenience, you can also hide it by modifying the port of apache, such as changing it to port 8567 instead of the default port 80.
I received a message from a netizen and suggested adding a password. Considering that it will not be abused, adding a password is somewhat necessary, but I don’t consider adding it to this article. I will write another article. Please refer to: http://www. 138vps.com/jzjc/1114.html
Recommended site searches: Chinese international domain names, overseas server rental prices, free virtual host servers, Wanwang domain name registration official website, what is domain name resolution, independent IP space, server rental, domain name registration prices, US hosting , buy space network,
发表评论