Making web interface accessible


I’m trying to set the UrBackup server in order to have it accessible from all the PCs in our network. I’m almost done… but I can only get the title bar and not the login form. :frowning:

I’m using a CentOS 7 as server, with Apache, mod_ssl, openssl correctly configured: at least, I can see Apache’s test page.

I added a sym-link in /var/www/html to the UrBackup web interface, and gave to all its directories the “+x permission” (otherwise Apache can’t read its contents).

Since Apache bundled with CentOS hasn’t got the “original” FastCGI in its repositories, I installed the “replacement” mod_fcgi. Then I added this configuration file in /etc/https/conf.d:

<Directory "/usr/share/urbackup/www">
    Options +FollowSymLinks
    AllowOverride None
    Require all granted

<IfModule dir_module>
    DirectoryIndex index.html index.htm

ProxyPass "/x" "fcgi://"

(I got here info about how to replace the FastCGIExternalServer line, from another topic in this forum)

As mentioned before, when I try to load UrBackup’s web interface from another PC, I can only see the header bar, without the menus, and a “hanging” rotating circle. I checked Apache’s ssl_access.log and it seems there’s a “404 - Not found” error: - - [03/Oct/2017:14:39:10 +0200] "POST /urbackup/x?a=login HTTP/1.1" 404 208

I also tried to change the last line in

ProxyPass "/urbackup/x" "fcgi://"

Nothing changes “from the outside”. This time the log recorded a “503 - Service unavailable” error: - - [03/Oct/2017:14:39:41 +0200] "POST /urbackup/x?a=login HTTP/1.1" 503 299

Is something else needed to set up the web server?

Make that two people with this problem. Can only get the title bar to load, and when inspecting the web page, I get this error “POST https://X.X.X.X/x?a=login 404 (Not Found).” It does make a reference to this Javascript “jquery.chash-9f7c65c84c8e8c3e317945e8fd89899b.js:4” in /usr/share/urbackup/www/js/ but my javascript skills are pretty not good enough to decipher what it is trying to do. Thanks

I installed today urbackup on debian 10 and got the apache2 with ssl to work. I used the home:uroni project hier:

After installing apache2 all you need to do is to enable the ssl, proxy and the proxy_fcgi modules:

a2enmod ssl proxy proxy_fcgi

then disable the default vhost:

a2dissite 000-default.conf

create urbackup vhost:

vim /etc/apache2/sites-available/urbackup.conf

with the following content:

<VirtualHost *:80>
	ServerAdmin webmaster@localhost
	ServerName urbackup.local.domain
	DocumentRoot /usr/share/urbackup/www/
	Redirect permanent / https://urbackup.local.domain/

	ErrorLog ${APACHE_LOG_DIR}/error.log
	CustomLog ${APACHE_LOG_DIR}/access.log combined


<IfModule mod_ssl.c>
	<VirtualHost _default_:443>
		ServerAdmin webmaster@localhost
		ServerName urbackup.local.domain
		DocumentRoot /usr/share/urbackup/www/

		ServerSignature Off
		SSLProxyEngine On
		ProxyPreserveHost On
		ProxyPass "/x" "fcgi://localhost:55413"

		ErrorLog ${APACHE_LOG_DIR}/error.log
		CustomLog ${APACHE_LOG_DIR}/access.log combined

		SSLEngine on
		SSLCertificateFile	/etc/ssl/certs/mycert.crt
		SSLCertificateKeyFile /etc/ssl/private/mykey.key

		<FilesMatch "\.(cgi|shtml|phtml|php)$">
				SSLOptions +StdEnvVars
		<Directory /usr/lib/cgi-bin>
				SSLOptions +StdEnvVars

# vim: syntax=apache ts=4 sw=4 sts=4 sr noet

You need to adjust the ServerName and the mycert.crt and mykey.key.
Last step is to enable you vhost and restart apache2:

a2ensite urbackup.conf
service apache2 restart

I hope this will help some one.

1 Like