RustPOS is a simple web-based Point of Sale system written in Rust. It is very easy to get going, does not require any additional setup and consists of a single executable for everything, with an additional optional print client available should you want to run the main program on a separate dedicated machine.
This is a simple implementation using modern technologies. It was born out of my frustration with free and open source POS software often being very brittle and relying on heavyweight technology stacks.
Note
This project is a functional proof of concept and not certified to be used in a production environment. It also may not meet the requirements of your fiscal authorities. Please check your local laws and regulations before using this software to perform sales.
- Completely configurable categories and items for sale via web UI
- Supports running tabs
- Change calculation
- Quick cash function
- Sales report generation: day, month, and custom date range reports with CSV export
- POS printer support (built into main application)
- Optional remote printer client (for dedicated server/cloud setups)
- Kitchen display
- User accounts and user roles (admin, cashier, cook)
- Simple inventory tracking
- Bright and Dark mode support
- All-Rust solution
- Leptos and Webassembly powered web UI, no javascript
- SQLite database
- Localized into several languages
RustPOS is provided in various installable packages. Simply install the applicable one. System services are provided for starting/stopping the program: sudo systemctl start rustpos starts the main program. The optional remote printer client can be started with sudo systemctl start rustpos-printclient
To start the programs on system boot, enable the services as follows:
sudo systemctl enable rustpos
or
sudo systemctl enable rustpos-printclient
After installing and starting RustPOS, open the url https://127.0.0.1:3000/ in your browser. A language selection screen should be visible. Note that the language and all settings can be changed during operation too.
Then select the desired currency:
Afterwards, an admin account with a random PIN will be created. Remember that PIN, it will not be shown afterwards! If a receipt printer is connected, the PIN will also be printed out.
Continue and log in with the admin account:
You should be greeted by the main POS screen, which will be empty because there are no categories and items defined:
Start by defining some categories:
Then add the actual items for sale. You can upload item images and set a stock amount. If you check "Kitchen item", the item will be sent to and tracked by the kitchen display if ordered.
Next, we recommend setting up user accounts by clicking on "Settings":
You can create admins, cashiers and cooks, and set their PIN. Cashiers can only register sales and monitor the kitchen progress, cooks can only access and manage the kitchen display.
Note
Now may be a good time to change the admin PIN!
Making a sale is simple: Create a new transaction, optionally entering a customer name first. If you enter no name, then the customer will be labeled as "Walk-in". Customer names are useful for running tabs.
Now add items to the sale:
You can press any of the quick cash buttons to display the change amount. Pressing Checkout will close the sale and print the receipt. Pressing Back will keep the transaction open but allow a different transaction to start. This is the equivalent to a running tab, and you can use the customer name feature to quickly find the correct transaction in the open transaction list:
Once a sale is closed, the last sale's change value will still be displayed so you can fetch change from the drawer:
You can also always go to the transactions list and expand any transaction to see the money paid and the calculated change:
RustPOS will enumerate all receipt printers connected via serial port or USB, and use the first one it finds. Obviously this won't work for all setups, but for this proof of concept it should suffice. The printout is designed for 80mm receipt printers and have been tested using a Munbyn ITPP098 connected via USB.
It may be necessary to run RustPOS on a dedicated machine or even in the cloud. In these cases, connecting a printer to the server may not be possible, and the printing should happen at the point of sale. For this reason there is a seperate print client available. This print client will connect to the main RustPOS installation via websocket, authenticate, download the receipt logo from the server, and then wait for print jobs.
Note
You do not need to install the print client if you run RustPOS itself on your POS. It will detect locally connected printers and use them directly.
The print client will install in /opt/rustpos-printclient and the configuration file is /opt/rustpos-printclient/printclient.toml
First, on the main RustPOS administration page, configure a Printer Passphrase:
Then edit /opt/rustpos-printclient/printclient.toml on the machine the printer is connected to, and insert the passphrase as well as the address of the main RustPOS installation.
Note
If your main RustPOS installation is available via HTTPS, the server_url should start with "wss", like in this example:
server_url = "wss://myserver.example.com"
The receipt logo image will be transfered from the main program after authentication. However, it can also be overridden in the print client configuration TOML.
Cooks can access the kitchen display via the url /kitchen. They are automatically redirected to that URL when logging on.
On the POS, there's a Kitchen tab that lets the cashier check the live status of every kitchen order.
A customer display can be accessed at the url /display. This will show items in the order as well as the total. The transaction will remain visible for one minute after the sale has been closed.
RustPOS supports sales reports with CSV export.
It is possible to change the logo used on the web UI. After installing the .deb package, the logo is at /opt/rustpos/site/logo_site.png
The receipt image is at /opt/rustpos/data/logo_receipt.png and can be replaced with your own B/W image.
Item images and the entire POS database is stored in the data directory. If you installed via .deb package, the location will be /opt/rustpos/data
# Install Trunk (build tool for Rust WASM apps)
cargo install trunk
# Install WASM target
rustup target add wasm32-unknown-unknown
The build script build.sh will build the application and copy all the neccessary files into the "rustpos" subdirectory.
You can copy that directory anywhere you want for a more permanent installation.
# Build application
./build.sh
# Run application
cd rustpos
./rustpos