Skip to content

hosler/inveterate

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Contributors Forks Issues MIT License

Inveterate Proxmox API

Hyper simplified Proxmox API wrapper made for VPS hosting solutions
Explore the docs »

View Demo · Report Bug · Request Feature

Table of Contents
  1. About The Project
  2. Getting Started
  3. Usage
  4. Roadmap
  5. Contributing
  6. License

About The Project

There are many options available for managing Proxmox nodes and clusters while running a business. Almost all of them are first and foremost billing systems that allow you to install Proxmox support via plugins and modules. This design decision makes it very hard to customize the look and feel of your site. I started this project with the goal of taking the opposite approach where an easy to use Proxmox integration API is exposed to any app.

Here's why:

  • WHMCS and Blesta and their Proxmox plugins are crap
  • You should be able to create beautiful vuejs, react, or react sites to support your business
  • Billing systems shouldn't manage provisioning. Billing systems should manage billing.

(back to top)

Built With

(back to top)

Getting Started

Besides a proxmox node you will also need a machine to run the app (perhaps a vps :)

Prerequisites

  • Postgresql 13
  • Redis
  • Optional: Nginx or Apache for reverse proxy
$ sudo apt install postgresql postgresql-contrib redis-server nginx libpq-dev -y

Installation

Basic installation with Ubuntu Focal Server

  1. Set up your environment using conda, virtualenv, or whatever. In this example i'll use Ubuntu's packaged python and pip. Ubuntu Focal users will need to run the following:
$ sudo update-alternatives --install /usr/bin/python python /usr/bin/python3 1
update-alternatives: using /usr/bin/python3 to provide /usr/bin/python (python) in auto mode
  1. Install pip:
$ sudo apt install python3-pip -y
  1. Clone and install requirements
$ git clone https://github.com/hosler/inveterate.git
$ cd inveterate
$ pip install --user -r requirements.txt
  1. Populate the env file
$ vim .env

At a minimum you will need database and redis info:

DEBUG=on # Turn off in production
REDIS_HOST=localhost
DB_HOST=localhost #leave blank to use socket
DB_USER=<username>
DB_PASSWORD=<paassword>
DB=<username>
SECRET_KEY=randomstring
  1. Setup tables and admin user
$ python manage.py makemigrations
$ python manage.py migrate
$ python manage.py createcachetable
$ python manage.py createsuperuser

(back to top)

Usage

Inveterate was designed to run via supervisord and sit behind a reverse proxy. Let's go ahead and set that up.

$ cd ~/inveterate
$ mkdir logs
$ vim supervisord.conf

Here is a basic supervisor config file

[supervisord]
logfile = ~/inveterate/supervisord.log
childlogdir = ~/inveterate/logs
logfile_maxbytes = 50MB
pidfile = ~/inveterate/supervisord.pid
directory=~/inveterate


[inet_http_server]
port=127.0.0.1:9001

[supervisorctl]
serverurl=http://127.0.0.1:9001

[rpcinterface:supervisor]
supervisor.rpcinterface_factory = supervisor.rpcinterface:make_main_rpcinterface

[program:celery_worker]
numprocs=1
process_name=%(program_name)s-%(process_num)s
command=celery -A app worker -l INFO --concurrency=4 -Q celery
autostart=true
autorestart=true
startretries=99999
startsecs=10
stopsignal=TERM
stopwaitsecs=7200
killasgroup=false
stdout_logfile=/dev/stdout
stdout_logfile_maxbytes=0
stderr_logfile=/dev/stderr
stderr_logfile_maxbytes=0


[program:celery_beat]
numprocs=1
process_name=%(program_name)s-%(process_num)s
command=celery -A app beat -l INFO --scheduler django_celery_beat.schedulers:DatabaseScheduler
autostart=true
autorestart=true
startretries=99999
startsecs=10
stopsignal=TERM
stopwaitsecs=7200
killasgroup=false
stdout_logfile=/dev/stdout
stdout_logfile_maxbytes=0
stderr_logfile=/dev/stderr
stderr_logfile_maxbytes=0

[program:inveterate]
command=gunicorn -k gevent -b 127.0.0.1:8000 --worker-connections=1000 --timeout 60 --workers 4 app.wsgi
autostart=true
autorestart=true
stdout_logfile=/dev/stdout
stdout_logfile_maxbytes=0
stderr_logfile=/dev/stderr
stderr_logfile_maxbytes=0

(back to top)

Roadmap

  • Stripe Support
  • Proxmox Clusters
  • Customer Life Cycles
  • Plans and Templates
    • KVM
    • LXC
  • Inventory Management
    • Clusters
    • Nodes
    • IP Pools
  • Health Monitoring
    • VM Stats
    • Cluster Stats
  • VM Controls
    • Start/Stop/Provision
    • Console
  • Domain Management
  • NAT port forwarding
  • Documetation

See the open issues for a full list of proposed features (and known issues).

(back to top)

Contributing

Contributions are what make the open source community such an amazing place to learn, inspire, and create. Any contributions you make are greatly appreciated.

If you have a suggestion that would make this better, please fork the repo and create a pull request. You can also simply open an issue with the tag "enhancement". Don't forget to give the project a star! Thanks again!

  1. Fork the Project
  2. Create your Feature Branch (git checkout -b feature/AmazingFeature)
  3. Commit your Changes (git commit -m 'Add some AmazingFeature')
  4. Push to the Branch (git push origin feature/AmazingFeature)
  5. Open a Pull Request

(back to top)

License

Distributed under the LGPLv3 License. See LICENSE.txt for more information.

(back to top)

About

Proxmox api wrapper for react

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages