Proxmox Control Panel Documentation

Proxmox Panel


Introduction

This product need a certain level of technical expertise. If you don't know what you are doing, you might break the System and cause bad things to happen.


First of all, Thank you so much for purchasing this template and for being my loyal customer. You are awesome!
You are entitled to get free lifetime updates to this product + exceptional support from the author directly.

This documentation is to help you regarding each step of customization. Please go through the documentation carefully to understand how this product is working and how you can work with it.

Requirements

You will need the following sofwares to install and use this product:

  1. Web Browser for testing (eg: Google Chrome or Mozilla Firefox)
  2. A Server with the following tools installed:
    1. Basic-Server: (see instructions here)
  3. A Server with Proxmox 6.1 installed.

Getting Started #back to top

Let's get started installing the Interface on your Server. For demonstration purposes, imagine I use a Debian 9.8 Server during this installation process.

In theory the process is pretty simple:

  1. Download Code & unpack
  2. Import Databasev
  3. Edit config
  4. Install Dependencys & run

Download Code & unpack

Your download key can be found in the CIS under the "Products"-tab (https://bennetgallein.de/cis/products)

                                    root@server:/var/www/html# sudo apt install unzip && wget --prefer-family=IPv4 https://bennetgallein.de/api/download-key/...
                                

Once downloaded, rename the file:

                                    root@server:/var/www/html# mv <file> cp.zip
                                

And unpack it:

                                    root@server:/var/www/html# unzip cp.zip
                                

Import Database

As said, I assume that you already have a MySQL Database installed on your System (prefferable a MariaDB 10.1.37 Server).

Let's enter the Database over the command line tool.

                                    root@server:/# mysql -u root
                                

If you have a password for the root user, use this command:

                                    root@server:/# mysql -u root -p
                                

After you logged in to the Database, you should see something like this:

                                    MariaDB [(none)]>
                                

You see it? Great! Let's create the Database:

                                    MariaDB [(none)]> CREATE DATABASE PMCP;
                                    Query OK, 1 row affected (0.01 sec)

                                    MariaDB [(none)]>
                                

Now you want to exit the Database. Use exit; to do that.
Now we want to import the Database. The easiest thing is to use the command line or a tool like phpmyadmin if that is installed:

                                    root@server:/# mysql -u root -p PMCP < /var/www/html/database.sql
                                

Install Dependencies and run

Now, we are basically finished. We just need to install the Dependencies, create an Account and give it Admin rights.

                                    root@server:/var/www/html/# chmod +x ./bin/install.sh && sudo ./bin/install.sh
                                

This will install all the dependencies the Interface needs, if errors accour during the installation, try fixing them by googleing.

Continue by downloading all permission and language files required.

                                    root@server:/var/www/html/# chmod +x ./bin/download_language_files.sh && sudo ./bin/download_language_files.sh
                                

Edit config

Now onto the important point on this list to make everythink work just the way you expect it to. If you do not have an config.json by this point (should be created by the script above)

                                    root@server:/var/www/html# cp config.json.example config.json && nano config.json
                                

The table below shows the key-value pair for each config entry you are advised to set now. You can ignore all other variables, since they can be set afterwards.

Key Example Value
APP_URL "/" This is the URL of your application. If you want it to run on yourdomain.com/ enter /, otherwise the path like /Proxmox/
DB_HOST "localhost" The Host of your Database. Should be localhost, 127.0.0.1 or your IP.
DB_USER "root" The User with which to access the Database.
DB_PASSWORD "root" The passwort of the Database user specified in DB_USER. Enter "" if you dont want to enter a password
DB_NAME "PMCP" The name of the Database which you'll have create with the steps above. If you followed the tutorial, enter PMCP
LANGUAGE "de" The language you want to use.

Save everything once you are done with editing and exit.

First login

Now, that everything is installed and ready to go, we can open the product in a browser.

You should be greeted with this login screen:

Click on register to get to the registration site, create a user and login with that user.

Now, navigate to the settings by dropping down them down and clicking on general.

First step should be to set your own logo, by inputting the URL in the LOGO Field.

Connecting Proxmox

Now, we want to configure the panel to work with our proxmox server.

Set the Proxmox IP to the IP-Adress of your Proxmox Host, Proxmox user to the user of your proxmox system and Proxmox password to the password from the user. The Proxmox Node ist the Server where the templates for the VMs are loaded from. In my case this is dev-01 (highlighted in the screenshot), so I enter that in there. If you are using multiple nodes in your cluster the templates need to be on a networkshare and accessible to all nodes. Otherwise creating a VM on a different node will result in an error.

Setting limits

In order to limit how much resources will be used on any node, you can set a percentage that will be used at maximum.

In the image below, you can see that I set 80% for each node in my cluster and 90 for dev-03.
If the nodes are equal in size, this would mean that dev-03 can use more resources for VMs than dev-01 and dev-02 which are allowed the same.

If you added a new node to your cluster, you can set the limit by entering it in the field for node-name together with the limit and click "save".

Invoice

Next, we want to set the invoice-stuff correctly.

INVOICE_1 to INVOICE_4 are the lines for the Adress in the Invoice. Put the VAT-Rate in there as a full number (example: 16)

Set the Email client data here. This will be used whenever the panel sends emails to customers. So have that setup correctly. If you do not have a E-Mail Server you can use, we recommend having a look at our hosted offer: Hosted Mail.

Pricing

Next, we want to set up pricing. This is a little bit more complicated, so please stick with me.

As you can see here, i've set the basic-price for a cpu to 2 and the default amount to 1. This means, that the lowest amount of CPU a customer can choose is 1 Core for 2 Euros.

Next, i've set the price for "each extra" to 0.50 Euros, which would mean, that from the default amount each step (1 for CPUs) will cost 50 cents. The maximal amount a customer can choose is set to 8 cores.

If a customer now chooses to buy a 4-core server, the price would be 2 € + 3 * 0.50 € = 3.50 €. This is the same principal behind disk (HDD Space) and RAM.

IP Adresses

IP Adresses need to be added manually so the system can give them to VMs that are being created.

Here is the overview of IPs, we can add new ones by clicking the button on the top right.

You will be asked to enter the IP-Address, the Netmask and the Gateway. This allows you to enter more than one IP at a time.

The Panel will not be able to create servers when there are no free IPs left!

Hetzner (and probably others)

In a briged network configuration (which is the only the Panel supports as of this version) proxmox needs a MAC-Address in the network adapter. This is not set automatically, so the field can be left empty when entering an IP-Block.

By checking the box marked in the image above the panel will set the MAC-Address from the IP in the network adapter from the VM.

PayPal

Now, we need to give customers a way to add balance to their account. This is not that complicated, we need to create a new application at PayPal and paste the public- and secretkey in the settings page.

Go to PayPal Developer Dashboard and login with your PayPal Account.

Now, click on the tab "Live" and then "Create app" like shown in the screenshot below:

Give the app a name and you are presented with a Client ID and a secret, which you have to click on "show" to see.

Now, you enter the credentials in the settings-tool and put the mode into "production". And now customers can add balance to their account via PayPal.

Proxmox Templates

In order for your customers to select an operating system while creating their server, you need to setup VM templates on the proxmox host.

Templates are basically cloud-init OS templates, that are converted to proxmox templates.

I will now demonstrate how to setup a Debian 10 Template. I'll be using the CLI for most of the steps.

First, I login to my Proxmox host over SSH.

                                    root@dev-01:~# wget https://cloud.debian.org/images/cloud/buster/20200803-347/debian-10-generic-amd64-20200803-347.qcow2
                                    root@dev-01:~# qm create 9001 --name "debian-10-cloudinit-template" --memory 2048 --net0 virtio,bridge=vmbr0
                                    root@dev-01:~# qm set 9001 --scsihw virtio-scsi-pci --scsi0 local-lvm:9001/vm-9001-disk-0.raw
                                    root@dev-01:~# qm set 9001 --scsihw virtio-scsi-pci --scsi0 local-lvm:vm-9001-disk-0
                                    root@dev-01:~# qm set 9001 --ide2 local-lvm:cloudinit
                                    root@dev-01:~# qm set 9001 --boot c --bootdisk scsi0
                                    root@dev-01:~# qm set 9001 --serial0 socket --vga serial0
                                    root@dev-01:~# qm template 9001
                                

First, we are downloading a cloud-image from the debian CDN. Debian is not the only Operating System that offers such cloud images, so it should be easy to find them from other vendors.
After that, we are creating a VM with the ID 9001 (the ID can be random, but I choose 9000 or above for all templates, since it's unlikely i'll create that much VMs ever).
Then, we are importing the cloud-image into the local-lvm, which is the storage Proxmox uses. Then we are setting the scsi to PIC and are amounting the imported lvm volume to the VM, so we can boot from that.
Next up, we're attaching the cloudinit partition to the ide port number 2, and are changing the boot order so that the VM is always booting from the cloudinit disk.
In the last step, we are converting the VM into a template so we can use it in proxmox.

Next, we want a clean name in the OS-selection on the order-page. In order to do that, we have to change the name of the template.

The Panel will replace "-" with a space, so in Order to get "Debian 10" in the selection menu we have to Name it "Debian-10".