https://github.com/seemoo-lab/hardwhere
snipeit-it based asset management app
https://github.com/seemoo-lab/hardwhere
asset-management assets-management itam
Last synced: 6 months ago
JSON representation
snipeit-it based asset management app
- Host: GitHub
- URL: https://github.com/seemoo-lab/hardwhere
- Owner: seemoo-lab
- License: gpl-3.0
- Created: 2022-05-19T19:49:04.000Z (over 3 years ago)
- Default Branch: master
- Last Pushed: 2022-08-06T14:46:03.000Z (about 3 years ago)
- Last Synced: 2025-03-21T03:05:48.802Z (7 months ago)
- Topics: asset-management, assets-management, itam
- Language: Kotlin
- Homepage:
- Size: 766 KB
- Stars: 8
- Watchers: 6
- Forks: 2
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# HardWhere
SEEMOO Accessories Retrieval System (HardWhere)
App + who-lent-to-whom functions based on [snipe-it]
This repo contains the mobile app, the required snipe-it patches and the "lent-by" backend that works in tandem with [snipe-it]
The backend daemon ist expected to handle all of the example.com/HardWhere/* requests and exposes its own API and webview at this path.
Currently compatible with snipeit v5.4.3
[
](https://f-droid.org/packages/de.tu_darmstadt.seemoo.HardWhere/)
## Building the daemon
install requirements:
`apt install libssl-dev pkg-config`
For other distributions [see here](https://docs.rs/openssl/0.10.35/openssl/#automatic)Get rustc and run
`cargo build --release`[#snipe-it]: https://github.com/snipe/snipe-it
## Log settings for the daemon
The `RUST_LOG` environment vairable can be set. Examples:
`RUST_LOG=hardwhere_backend=trace` or for the full show `RUST_LOG=trace`
You can also specify it for multiple moduls `RUST_LOG=hardwhere_backend=debug,actix_web=trace`.Possible values are trace,debug,info,warn,error
## Example apache config for backend
Running the daemon together on the same machine with snipeit.
The daemon is expected to be present on /HardWhere for the app.
```apache2[...]
ProxyPass http://127.0.0.1:8000/HardWhere
ProxyPassReverse http://127.0.0.1:8000/HardWhere
ProxyPreserveHost On
```# Structure
- `src/` contains the additional backend, referred to as HardWhere-Backend or daemon, used for
- indexing who lent to whom
- providing return/lent APIs for the app, so the index in the backend is updated at the same time
- regularly making sure the default fieldset is applied to all models that have none
- providing a webview on https:///HardWhere/ for inspecting lent assets without using the app
- `static/` is part of the HardWhere-Backend, containing templates, CSS icons and other stuff for the webview, it's required to be relative to the daemon application
- `hardwhere.patch` contains code applied to snipeit to provide app login via QR code and auto-login from the snipeit menu into the HardWhere-Backend webview
- `app/` contains the sourcecode for the android app
- `res/` app resources## Workflow
You can open this folder as an android App in android studio and in VS Code for the HardWhere-Backend. It is recommended to use VS Code with the rust-analyzer plugin for it.You can build the app via gradle or in android studio. HardWhere-Backend can be build using `cargo build --release`, `--release` being optional.
For the integration with snipeit you'll have to upgrade hardwhere.patch for new snipeit versions.