Azelphur / TechnicSolder

Remake of https://github.com/TechnicPack/TechnicSolder

Home Page:https://solder.cf

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

TechnicSolder

License: MIT Latest Stable Version Latest Dev Version

TechnicSolder is an API that sits between a modpack repository and the Technic Launcher. It allows you to easily manage multiple modpacks in one single location.

Using Solder also means your packs will download each mod individually. This means the launcher can check MD5's against each version of a mod and if it hasn't changed, use the cached version of the mod instead. What does this mean? Small incremental updates to your modpack doesn't mean redownloading the whole thing every time!

Solder also interfaces with the Technic Platform using an API key you can generate through your account there. When Solder has this key it can directly interact with your Platform account. When creating new modpacks you will be able to import any packs you have registered in your Solder install. It will also create detailed mod lists on your Platform page! (assuming you have the respective data filled out in Solder) Neat huh?

-- Technic

TechnicSolder was originaly developed by Technic using the Laravel Framework. However, the application is difficult to install and use. Technic Solder - Solder.cf by TheGameSpider runs on pure PHP with zip and MySQL extensions and it's very easy to use. To install, you just need to install zip extension, setup MySQL database and download Solder to your server (No composer needed). And the usage is even easier! Just Drag n' Drop your mods.

Detailed Installation

Note: If you already have a working web server with mysql and zip extensions and enabled rewrite mod, you can skip to step 6.

1. Install Ubuntu Server 18.04 (https://www.ubuntu.com/download/server)
2. Login to Ubuntu with credentials you set.
3. Become root

sudo passwd root

Write your current password, then set new root password

exit

Login as root

Web server installation and configuration

4. Install WEB Server

apt update
apt -y install apache2 php libapache2-mod-php mysql-server php-mysql php-dev zlib1g-dev
``
The above command can take a while to complete. Now, you need to install PHP ZIP extension.<br />
```bash
cd /
wget http://fr.archive.ubuntu.com/ubuntu/pool/universe/libz/libzip/libzip4_1.1.2-1.1_amd64.deb
wget http://fr.archive.ubuntu.com/ubuntu/pool/universe/libz/libzip/libzip-dev_1.1.2-1.1_amd64.deb
dpkg -i libzip4_1.1.2-1.1_amd64.deb
dpkg -i libzip-dev_1.1.2-1.1_amd64.deb
pecl install zip
nano /etc/php/7.2/apache2/php.ini

add extension=zip.so to the second line. When you are finished, save and close the file by pressing Ctrl-X. You'll have to confirm the save by typing Y and then hit Enter to confirm the file save location.

service apache2 restart

Configure MySQL:

mysql_secure_installation

You will be asked if you want to configure the VALIDATE PASSWORD PLUGIN. Answer y
Then you'll be asked to select a level of password validation. Answer 0 and set your mysql password.
You'll be asked for a few more things, answer y to all.

nano /etc/apache2/mods-enabled/dir.conf

We want to move the PHP index file to the first position after the DirectoryIndex specification:
DirectoryIndex index.html index.cgi index.pl index.php index.xhtml index.htm -> DirectoryIndex index.php index.html
Configuration will look like this:

<IfModule mod_dir.c>
    DirectoryIndex index.php index.html
</IfModule>

When you are finished, save and close the file.

service apache2 restart
nano /var/www/html/index.php

This will open a blank file. We want to put the following text, which is valid PHP code, inside the file:

<?php
phpinfo();

When you are finished, save and close the file.
Now we can test whether our web server can correctly display content generated by a PHP script. To try this out, we just have to visit this page in our web browser. You'll need your server's public IP address.

curl http://icanhazip.com

Open in your web browser: http://your_server_IP_address
This page basically gives you information about your server from the perspective of PHP. It is useful for debugging and to ensure that your settings are being applied correctly.

You probably want to remove this file after this test because it could actually give information about your server to unauthorized users. To do this, you can type

rm /var/www/html/index.php

5. Enable RewriteEngine

a2enmod rewrite
nano /etc/apache2/sites-enabled/000-default.conf

Add this before </VirtualHost> close tag:

    <Directory /var/www/TechnicSolder>
        Options Indexes FollowSymLinks MultiViews
        AllowOverride All
        Require all granted
    </Directory>

Save and close the file

Cloning TechnicSolder repository

6. Clone TechnicSolder repository

cd /var/www/
git clone https://github.com/TheGameSpider/TechnicSolder.git
nano /etc/apache2/sites-enabled/000-default.conf

Change DocumentRoot to /var/www/TechnicSolder
Restart apache

service apache2 restart

If you don't have remote access to the server (SSH), you can just download the master branch extract it to your document root folder
Installation is complete. Now you need to confige TechnicSolder before using it.

If you are using nginx:

there is an example for nging configuration"

	location / {
        try_files   $uri $uri/ /index.php?$query_string;
        }

	location /api/ {
        try_files   $uri $uri/ /api/index.php?$query_string;
        }

    location ~* \.php$ {
            fastcgi_pass                    unix:/run/php/php7.2-fpm.sock;
            fastcgi_index                   index.php;
            fastcgi_split_path_info         ^(.+\.php)(.*)$;
            include                         fcgi.conf;
            fastcgi_param PATH_INFO         $fastcgi_path_info;
            fastcgi_param SCRIPT_FILENAME   $document_root$fastcgi_script_name;
    }

    location ~ /\.ht {
            deny all;
    }

    location ~ .*/\. {
            return 403;
    }

    error_page 403 /403.html;
    
    location ~* \.(?:ico|css|js|jpe?g|JPG|png|svg|woff)$ {
            expires 365d;
	}

Configuration

configure MySQL

mysql -p -u root

Login with your password you set earlier.
Create new user

CREATE USER 'solder'@'localhost' IDENTIFIED BY 'secret';

NOTE: By writing IDENTIFIED BY 'secret' you set your password. Dont use secret


Create database solder and grant user solder access to it.

CREATE DATABASE solder;
GRANT ALL ON solder.* TO 'solder'@'localhost';
exit

Configure TechnicSolder

chown -R www-data TechnicSolder

Go to http://your_server_IP_address and fill up the form. If you followed these instructions, database name and username is solder

The final step is to set your Solder URL in Solder Configuration (In your https://technicpack.net profile)

http://your_server_IP_address/api/

Click Link solder

That's it. You have successfully installed and configured TechnicSolder. It's ready to use!

About

Remake of https://github.com/TechnicPack/TechnicSolder

https://solder.cf

License:Other


Languages

Language:PHP 99.8%Language:HTML 0.2%