- Install system packages: gcc, libssl-dev, pkg-config
- cargo install trunk
-
Start the wasm web client builder in watch mode
cd ng_web trunk watch
-
Start the api server, it will also serve the latest web client
RUST_LOG=debug cargo run --bin ng_server
By default the data is stored in SQLite memory database.
-
Build the web client artifacts
cd ng_web trunk build --release
-
Build the api server binary, this will include the web artifacts
cargo build --bin ng_server --release
To run the resulting self contained binary use RUST_LOG=debug target/release/ng_server
.
In test or release mode the web client can be found at: http://127.0.0.1:8081/
docker build -t nonce_guess .
docker run -d --rm -it -p 8081:8081 -v nonce_vol:/data --name nonce_guess_app nonce_guess
- Visit http://127.0.0.1:8081/ in a browser
Note: above steps also work with podman
instead of docker
.