Installation
Docker
You can build an image yourself using the compose file provided, ensure that you have docker and docker compose installed. Instructions can be found in Prerequisites.
You also need to edit the config.php file to uncomment and recomment some lines for the sql credentials.
git clone https://github.com/GoldDominik893/liberatube.git
cd liberatube/
nano config.php
sudo docker-compose up -d --build
Verify that Liberatube has been installed by going to 127.0.0.1:80
. You should also follow the Post Install configuration for extra options and settings.
Installing on a Hosting Provider
- Download the latest Version of Liberatube from the repository on GitHub.
- Extract the zip file.
- Upload the contents of the folder to your websites root directory.
- Edit the
config.php
file to adjust the database credentials. - Go to the website to see if it is installed properly.
That should be it but some Hosting Providers do no give you proper permissions to create a database, instead you need to use their web interface. Please follow the steps below to import the database manually.
- Log in to your Hosting Provider's dashboard and find where you can create a MySQL database and make one called
users
. -
Edit the
database.sql
file and remove the first 5 lines -
Log in to the phpMyAdmin for your database and import the database.sql file you edited.
- Rename your
database.sql
file todatabase.sql.executed
.
Manual Install
Installing Manually requires all the Prerequisites to be installed before doing any of the following.
Clone the Git Repository
Edit the config.php file to have the correct database credentials.
Edit these 4 lines
$servername = "localhost"; // The IP / domain used to connect to your database
$username = "root"; // The database username
$password = ""; // The database password
$dbname = "users"; // The database name, by default, if you imported database.sql it is "users"
Tip
If you don't want to use a SQL database you can do so by changing a setting in the config.php
file.
Move the contents of ~/liberatube/ to /var/www/html (this may require root privileges)
Now Liberatube will be accessible at 127.0.0.1:80
, but it requires an SQL database to operate.
MySQL setup
Liberatube automatically imports the database.sql file using the credentials provided. Although, MySQL now requires you to create a new user as it wont let you use the root user.
Follow these instructions to create a new MySQL user:
Enter the MySQL server as root
And run the following commands in the shell to make a new user but make sure to put your own password
CREATE USER 'liberatube'@'localhost' IDENTIFIED BY 'changethis';
GRANT ALL PRIVILEGES ON users.* TO 'liberatube'@'localhost';
FLUSH PRIVILEGES;
EXIT;
And lastly you should update the credentials in your config.php
.
Success
After doing all of that, Liberatube is considered to be installed and working although you should follow the Post Install configuration for extra options and settings.