The following warnings occurred:
Warning [2] Undefined variable $unreadreports - Line: 26 - File: global.php(961) : eval()'d code PHP 8.1.2-1ubuntu2.14 (Linux)
File Line Function
/global.php(961) : eval()'d code 26 errorHandler->error
/global.php 961 eval
/showthread.php 28 require_once





× This forum is read only. As of July 23, 2019, the UserSpice forums have been closed. To receive support, please join our Discord by clicking here. Thank you!

  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Tutorial: UserSpice requirements
#1
UserSpice requirements and installation.

Since I haven't been able to find any resources how to configure my own server for UserSpice, I thought this could be helpful for somebody in the future.

Note: this tutorial was written for Debian 8
It will probably be okay with other distros too. Maybe some google searching if command is not found.

Note: this tutorial assumes, that you have installed working unix server.

Step 1: Install Apache
Apache is responsible for converting your machine into a web server. See What is Apache?

run # sudo apt-get install apache2

If you are configuring your server via SSH, you are probably not logged in as root. If you are not root, you will have to change some permissions, so you will have full access to default directory of your website. Default directory it is set to /var/www/html. If you would like to change default directory, just ask google. There are many versions of apache, so it is likely that my solution does not work for you. In my case I had to change file /etc/apache2/sites-available/000-default.conf.

Change permissions:
run # sudo adduser <username> www-data
where <username> is username of debian
run # sudo chown -R www-data:www-data /var/www
run # sudo chmod -R g+rwX /var/www

Step 2: LetsEncrypt
This step is optional, but since trend is going into TLS (What is TLS?), you will probably be better if you secure your website with encoding. If you are not running Debian, check installation instructions on LetsEncrypt Certbot.

Add this line
Code:
deb http://ftp.debian.org/debian jessie-backports main
to your sources.list (/etc/apt/sources.list)

run # sudo apt-get install python-certbot-apache -t jessie-backports
run # certbot --apache
Now follow instructions and select always redirect item when it prompts you.

Add this line
Code:
Redirect permanent / https://mysite.example.com/
to apache configuration file (/etc/apache2/sites-available/000-default.conf). This line must be added into between <VirtualHost *:80> tags.

run # sudo certbot renew --dry-run

If you encounter any errors with last command, check your IPv6 settings and google for solution.

Step 3: Install PHP
run # sudo apt-get install php5 libapache2-mod-php5

This will install PHP 5.6. If you would like to try PHP7 just google for solution.

Step 4: MySQL
run # sudo apt-get install mysql-server php5-mysql
run # sudo mysql_secure_installation

Setup will ask you few questions. If you already set password for root type "n" for the first question. All other questions you can answer with "y"

Step 5: PHPmyAdmin<strong>
run # apt-get install phpmyadmin

You will see the following questions:
  • Web server to reconfigure automatically: <-- apache2
  • Configure database for phpmyadmin with dbconfig-common?<-- Yes
  • Password of the database's administrative user: <-- Enter the MariaDB root password
  • MySQL application password for phpmyadmin: <-- Press enter, apt will create a random password automatically

Now open your web browser and navigate to mysite.com/phpmyadmin
Login with username root and password you set for MySQL.

From now on you can watch Dan's video about installing UserSpice. You can get it under Documentation/Installation and Setup on UserSpice website.
  Reply
#2
Thanks so much for this!
  Reply
#3
Seriously, thank you!

I just went through your tutorial on my Linode. I only ran into issues with your LetsEncrypt step. I got it to work eventually, but I think you just need to add/run

apt-get update && apt-get upgrade

after you edit the sources.list file.

Also, I'm new to all of this: what is the difference between the database's administrative user's password and the MySQL application password for phpmyadmin? Specifically, when is the database's administrative user's password used?

Thank you again for this tutorial!
  Reply
#4
The DB admin password is one of those things that can be different from your db user password, but isn't always. It's 100{3bc1fe685386cc4c3ab89a3f76566d8931e181ad17f08aed9ad73b30bf28114d} tied to however your server was setup.

I guess if there is a rule of thumb...if I setup a server for a single purpose, it's usually the same. If it's going to be doing a bunch of websites, each site gets its own password and db user.
  Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)