StockazNG is an open-source web-based inventory management system. It provides features such as inventory tracking, product categorization, and low stock alerts, among others. This tutorial will guide you through the installation of StockazNG on Debian Latest.
Before proceeding with this tutorial, please ensure that you have the following:
The first step is to ensure that all the necessary packages are installed. Open a terminal and run the following command:
sudo apt-get update && sudo apt-get -y install git python3 python3-pip python3-venv mysql-server libmysqlclient-dev
git
package is used to clone the StockazNG repository from GitHub.python3
package is required to run the application.python3-pip
package is a package manager for Python.python3-venv
package allows you to create Python virtual environments.mysql-server
package is required to set up a MySQL database.libmysqlclient-dev
package is required for Python's MySQL database connector.The next step is to clone the StockazNG repository from GitHub. In the terminal, run the following command:
git clone https://dev.sigpipe.me/dashie/StockazNG.git
Once the repository is cloned, navigate to the StockazNG directory and create a Python virtual environment:
cd StockazNG
python3 -m venv env
Next, activate the virtual environment:
source env/bin/activate
Install the required Python packages with pip:
pip3 install wheel
pip3 install -r requirements.txt
Now it's time to create a MySQL database for StockazNG. Run the following command in the terminal to log in to MySQL as the root user:
sudo mysql -u root
Once you are logged in to MySQL, create a new database and user:
CREATE DATABASE stockazng;
GRANT ALL PRIVILEGES ON stockazng.* TO 'stockazng'@'localhost' IDENTIFIED BY 'password';
FLUSH PRIVILEGES;
In the above example, we have created a new database called stockazng
and a new user called stockazng
with the password password
.
Next, create a configuration file for StockazNG:
cp stockazng.cfg.example stockazng.cfg
Edit stockazng.cfg
and add the database information:
DATABASE_USER = 'stockazng'
DATABASE_PASSWORD = 'password'
DATABASE_NAME = 'stockazng'
To start the application, run the following command:
./stockazng.py
The application should now be running on http://localhost:8080
.
In this tutorial, you learned how to install and configure StockazNG on Debian Latest. You also learned how to set up a MySQL database and create a user for the database. You can now start using StockazNG to manage your inventory.
If you want to self-host in an easy, hands free way, need an external IP address, or simply want your data in your own hands, give IPv6.rs a try!
Alternatively, for the best virtual desktop, try Shells!