Hi All,
This is my second monthly update report. Before talking about specific achievements, I would like to describe briefly how the Satellite is designed (this design idea has been crystallizing and getting a more solid shape over the last couple of months).
The Satellite is essentially based on siad
, which saves me a lot of time, because I can leverage the already existing code. Gateway, Consensus, TransactionPool, and Wallet modules are all imported from go.sia.tech/siad
packages. Further, two new modules are introduced: Satellite and Portal. Portal provides the API that can be accessed via the web portal, while Satellite is where all the magic will happen.
A Satellite node will be an intermediary between the renters and the hosts, so it essentially consists of two major parts. The host-facing part is called Manager, and it inherits a lot from the Renter module of siad
. It has a HostDB and a Contractor subsystems, which are responsible for the host selection and the contract formation. The renter-facing part is called Provider, and it will interact with the renters by accepting the contract formation requests and sending ready contracts. A renter using a Satellite node does not have to run their own Wallet module; this one will be provided by the Satellite.
Which brings us to the question: How will the renter pay for the contracts without a Wallet module? Quite simple - via the Portal (and the web portal). A renter who wants to use a Satellite node registers an account at the web portal, creates a payment plan, and commits a payment in a fiat currency. After a successful payment, they receive an email containing the renter seed, which they need to put in the config file of their renterd
software (still to be figured out). This seed is generated deterministically from the user email address and the wallet seed of the Satellite node, so it is guaranteed to be unique.
What has been achieved during the last month:
- Users can now pay with the real credit cards, and their balances will be updated on the dashboard. As the service in not implemented yet, a proper warning was posted on the web portal.
- HostDB now uses MySQL to persist the host entries. Loading the entries on startup was moved to a goroutine, so the startup takes now much shorter than before.
- A command-line client,
satc
, was made similarly to siac
.
- A custom Contractor was implemented. The major difference with
go.sia.tech/siad/modules/renter/contractor
is that in most methods, two public keys are passed (for the host and the renter) instead of just the host public key. The Contractor also uses MySQL to persist the contracts.
Now, the Manager part is mostly done for an MVP, and I will be focusing on the Provider part now.
As usual, the repo is located on GitHub - mike76-dev/sia-satellite: A network service that allows credit card payment for Sia storage., and the current state of the development can be tested live on Sia Satellite.
And thanks to The Foundation for the T-shirt! 