aaPanel, BaoTa and other panels
Installing HWD POS on a server managed by a web control panel such as aaPanel (宝塔 / BaoTa), cPanel or Plesk.
Installing on a server managed by a control panel is possible, but it is not the recommended method. The panel manages the web server and PHP in its own way, and the two background services have to be installed separately. If you can, use the network install on a clean server.
The essentials (any panel)
Whatever panel you use, these are the requirements:
-
Create the site and set its document root to the
public/folder. -
Use PHP 8.2+ and enable the extensions listed in the requirements.
-
Create the database and its user from the panel.
-
Give the folder to the web server user and allow writing to
storage/andpublic/uploads/. -
Install the two background services (printing and plugins):
sudo bash install-workers.sh /path/to/site web-userinstall-workers.shis not included in the.zippackage; get it from your vendor or from the same place as the installers. -
Open the setup wizard at
http://…/install.
aaPanel / 宝塔 (BaoTa)
aaPanel is the international edition of 宝塔 (BaoTa). Both work the same way.
Install the panel
On Ubuntu:
wget -O install.sh https://www.aapanel.com/script/install_6.0_en.sh && sudo bash install.shInstall the LNMP stack
In the panel, install Nginx, PHP 8.2 and MySQL/MariaDB.
Configure PHP
In PHP 8.2 → Extensions, enable pdo_mysql, mbstring, curl, zip, gd, xml, sodium, fileinfo and opcache.
In that PHP's Configuration, disable open_basedir or add the project path to it (the system writes to storage/).
Add the site
Add a site (domain or IP). Then, in the site settings → Site directory (运行目录), change the running directory to /public.
URL rewrite
In the site → URL rewrite (伪静态), paste:
location / { try_files $uri $uri/ /index.php?$query_string; }You can also use the reference configuration shown in Web server.
Create the database
Create a database in the panel and write down its user and password. You will need them in the setup wizard.
Permissions
Give the PHP user (usually www) write access to storage/ and public/uploads/.
Print worker
In the panel's Supervisor (进程守护), add a process that runs:
php /www/wwwroot/HWDPOS/scripts/print_worker.php --daemonIf you are going to print, install cups and chromium over SSH.
Open the site
Open the site in the browser. The /install setup wizard appears.
On a panel-managed server, the hwdpanel command and check.sh repairs are designed for the standard installer layout (/var/www/HWDPOS, systemd services). Some of their options may not apply.