How to setup and run walletd for your services

Hey guys, I’m starting off our educational series with a brief tutorial on how you can get walletd up and running. Once you have walletd up and running you can start making your own services with BUKZ! The possibilities are endless! Games, Payment Gateways, Marketplaces, and the list goes on and on.

Generate your container file

I’m assuming that you have the binaries already. The first step to getting your walletd daemon up and running is to generate your container file. This file is password protected and holds your wallets addresses, balances, and transactions. Navigate to the directory you have walletd (walletd.exe if on windows) and run the following command.

./walletd --container-file PoolWallet.bin --container-password PoolPassword --generate-container

Now once you’ve run this command the wallet will spit out your public address and some other information and then exit itself out.

WalletD --generate-container

You now have a PoolWallet.bin file in your current working directory. Make sure you use a strong password and be sure to save it somewhere, preferably write it down on paper and keep it in a locked file cabinet inside a secret room behind a bookshelf.

Create a configuration file

The next step in getting your walletd service up and running is to create a configuration file. Open up your editor of choice and fill it with the following settings.

rpc-user = rpcUser
rpc-password = rpcPassword
container-file = PoolWallet.bin
container-password = PoolPassword
bind-port = 1987

When you’re done it should look something like this:

Configuring WalletD

rpc-user is the username you will use to authenticate with your daemon
rpc-password is the password used to authenticate with your daemon
cointainer-file is the container file we just created that holds your service wallet’s information.
container-password is the password associated with the above container-file.
bind-port is the port our daemon will listen to accept RPC requests.

Once you’ve saved the file as “walletd.conf” or similar in the same directory as your walletd binary, we’re ready to start the daemon!

Launching the daemon

We’ve been given two options when launching our daemon, we can launch it alongside our bukzd service, or we can launch it with the –local option and it will function as both.

If you want to run walletd alongside bukzd:
./walletd --config walletd.conf

If you just want to launch the walletd service without bukzd:
./walletd --config walletd.conf --local


Now you’re all setup and ready to start communicating with your walletd service! Make something cool!

Leave a Reply