onepeerlabs / bee-lite

bee-lite is an embeddable, lightweight bee node for applications to use swarm directly

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

bee-lite

Go Reference

bee-lite is an embeddable, lightweight bee node for applications to use swarm directly

How to run

lo := &beelite.LiteOptions {
    FullNodeMode:             false,
    BootnodeMode:             false,
    Bootnodes:                []string{"/dnsaddr/mainnet.ethswarm.org"},
    StaticNodes:              []string{<STATIC_NODE_ADDRESSES>},
    DataDir:                  dataDir,
    WelcomeMessage:           "Welcome from bee-lite",
    BlockchainRpcEndpoint:    <RPC_ENDPOINT>,
    SwapInitialDeposit:       "10000000000000000",
    PaymentThreshold:         "100000000",
    SwapEnable:               true,
    ChequebookEnable:         true,
    DebugAPIEnable:           false,
    UsePostageSnapshot:       false,
    Mainnet:                  true,
    NetworkID:                1,
    NATAddr:                  "<NAT_ADDRESS>:<PORT>",
    CacheCapacity:            32 * 1024 * 1024,
    DBOpenFilesLimit:         50,
    DBWriteBufferSize:        32 * 1024 * 1024,
    DBBlockCacheCapacity:     32 * 1024 * 1024,
    DBDisableSeeksCompaction: false,
    RetrievalCaching:         true,
}

const loglevel = "4"
bl, err := beelite.Start(lo, password, loglevel)
if err != nil {
    return err
}

About

bee-lite is an embeddable, lightweight bee node for applications to use swarm directly

License:Apache License 2.0


Languages

Language:Go 99.6%Language:Makefile 0.4%